Documentation ¶
Index ¶
- func AddComponent[C Component](ctx *pulumi.Context, name string, component C) ([]pulumi.Resource, error)
- func Check(_ []pulumi.Resource, err error)
- type Cilium
- type Component
- type Flux
- type Gateway
- type InternalGateway
- type InternalGatewaysData
- type Loadbalancer
- type LocalPVAndPVC
- type NativeLinkGateways
- type NativeLinkRoutes
- type RebuildNativeLink
- type Registry
- type RouteConfig
- type TektonDashboard
- type TektonPipelines
- type TektonTriggers
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Gateway ¶
type Gateway struct { ExternalPort int InternalPort int Routes []RouteConfig }
type InternalGateway ¶
Gateway struct to hold name and IP.
type InternalGatewaysData ¶
type InternalGatewaysData struct { InternalGateways []InternalGateway Gateways []Gateway }
GatewaysData struct to hold multiple Gateways for templating.
type Loadbalancer ¶
A local loadbalancer.
type LocalPVAndPVC ¶
Configuration to create a PV and PVC which mount a node-local directory via `hostPath`.
type NativeLinkGateways ¶
func (*NativeLinkGateways) Install ¶
func (component *NativeLinkGateways) Install( ctx *pulumi.Context, name string, ) ([]pulumi.Resource, error)
Install sets up the Gateways for the NativeLink deployment.
Contrary to the rest of the NativeLink setup, these gateways aren't part of the regular deployment. Recreating the Gateways would change their local IPs which makes development less convenient. Instead, we create them once and take the IPs for granted to be fixed after initial creation.
It's unclear whether this indirection is the right approach and we might add them to the regular deployments when more infrastructure is in place to support changing Gateway IPs.
type NativeLinkRoutes ¶
func (*NativeLinkRoutes) Install ¶
func (component *NativeLinkRoutes) Install( ctx *pulumi.Context, name string, ) ([]pulumi.Resource, error)
Install sets up the Routes for the NativeLink deployment.
Contrary to the rest of the NativeLink setup, these gateways aren't part of the regular deployment. Recreating the Gateways would change their local IPs which makes development less convenient. Instead, we create them once and take the IPs for granted to be fixed after initial creation.
It's unclear whether this indirection is the right approach and we might add them to the regular deployments when more infrastructure is in place to support changing Gateway IPs.
type RebuildNativeLink ¶
func (*RebuildNativeLink) Install ¶
func (component *RebuildNativeLink) Install( ctx *pulumi.Context, name string, ) ([]pulumi.Resource, error)
Install installs a Tekton Task, Pipeline and EventListener and some supporting resources which ultimately allow querying the cluster at a Gateway named `eventlistener` with requests like so:
``` EVENTLISTENER=$(kubectl get gtw eventlistener -o=jsonpath='{.status.addresses[0].value}')
# If imageNameOverride and imageTagOverride are unset, they default to: # $(nix eval <flakeOutput>.imageName --raw) # $(nix eval <flakeOutput>.imageTag --raw)
curl -v \ -H 'content-Type: application/json' \ -d '{ "flakeOutput": "./src_root#image", "imageNameOverride": "nativelink", "imageTagOverride": "local" }' \ http://${EVENTLISTENER}:8080
```
This pipeline only works with the specific local setup for the NativeLink development cluster. The Task makes use of the double-pipe through volumes `host -> kind -> K8s` to reuse the host's nix store and local nativelink git repository. It then pushes the container image to the container registry which previous infrastructure setups configured to pass through from host to the cluster. The result is that these Pipelines can complete in <15sec as opposed to ~10min without these optimizations.
WARNING: At the moment the Task makes use of `SYS_ADMIN` privilege escalation to interact with the host's nix socket and the kind node's container daemon.
type RouteConfig ¶
Route struct representing a route with prefix, cluster, and optional gRPC field.
type TektonDashboard ¶
Configuration for the Tekton Dashboard.
type TektonPipelines ¶
type TektonPipelines struct {
Version string
}
The configuration for Tekton Pipelines.
func (*TektonPipelines) Install ¶
func (component *TektonPipelines) Install( ctx *pulumi.Context, name string, ) ([]pulumi.Resource, error)
Install installs Tekton Pipelines on the cluster.
This function performs an additional feature-flag transformation to set `disable-affinity-assistant=true` and `coscheduling=pipelineruns`.
type TektonTriggers ¶
The configuration for Tekton Triggers.