Local MacOS install
Install Task (opens in a new tab)
Install socket_vmnet (opens in a new tab)
installing socket_vmnet fixed issues that i had with rancher after cilium replaced networking
brew install socket_vmnet
echo 'export PATH="/opt/homebrew/opt/socket_vmnet/bin:$PATH"' >> ~/.zshrc
sudo brew services start socket_vmnet
sudo mkdir -p /opt/socket_vmnet/bin
sudo ln -s /opt/homebrew/opt/socket_vmnet/bin/socket_vmnet /opt/socket_vmnet/bin/socket_vmnet
Install Rancher Desktop (opens in a new tab)
Cillium for Rancher Desktop (opens in a new tab)
Instructions for the override file duplicated below
add override.yaml
file to the installation directory for Rancher Desktop (~/Library/Application\ Support/rancher-desktop/lima/_config/
)
override.yaml
env:
# needed for cilium
INSTALL_K3S_EXEC: "--flannel-backend=none --disable-network-policy"
provision:
# needs root to mount
- mode: system
script: |
#!/bin/sh
set -e
# needed for cilium
mount bpffs -t bpf /sys/fs/bpf
mount --make-shared /sys/fs/bpf
mkdir -p /run/cilium/cgroupv2
mount -t cgroup2 none /run/cilium/cgroupv2
mount --make-shared /run/cilium/cgroupv2/
task local:010-configure-rancher-desktop
Install CRDs for GatewayAPI
task local:020-add-gateway-crds
Install Cilium (opens in a new tab) with Gateway API support on the Rancher Desktop Cluster
Using Cilium CLI (opens in a new tab)
task local:030-cilium-install
Add Gateway API Class - if its missing from the cluster
⚠️
In my case, the class was missing from the cluster and cilium operator needs this to create the gateway.
cilium-gateway-class.yaml
apiVersion: gateway.networking.k8s.io/v1beta1
kind: GatewayClass
metadata:
name: cilium
spec:
controllerName: io.cilium/gateway-controller
task local:040-add-missing-gateway-class
Install Local Gateway
local-gateway.yaml
apiVersion: gateway.networking.k8s.io/v1beta1
kind: Gateway
metadata:
name: scry-gw
spec:
gatewayClassName: cilium
listeners:
- name: scry-web
port: 80
protocol: HTTP
allowedRoutes:
kinds:
- kind: HTTPRoute
task local:050-local-gateway-install
Install Local Postgres DB
ℹ️
Any local installation will do.
task local:060-postgres-install
Install Admin Directus
admin-values.yaml
replicaCount: 1
image:
repository: directus/directus
pullPolicy: IfNotPresent
tag: "10.6"
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
serviceAccount:
create: true
annotations: {}
name: ""
podAnnotations: {}
podSecurityContext: {}
securityContext: {}
service:
type: ClusterIP
port: 8065
ingress:
create: false
gatewayApi:
create: true
host: admin.local.scryapp.website
annotations: {}
gateway:
create: false
name: 'scry-gw'
namespace: 'default'
route:
matches:
- path:
type: PathPrefix
value: /
resources: {}
autoscaling:
enabled: false
env:
publicUrl: 'http://admin.local.scryapp.website'
key: 'BB1AFE70-F462-4C98-9935-6902EADA57A5'
secret: 'EF222AE9-10FB-4190-AD4C-C6E866D19EF2'
dbClient: 'pg'
dbHost: 'postgres-postgresql-hl.default.svc.cluster.local'
dbPort: '5432'
dbDatabase: 'scry'
dbUser: 'scryuser'
dbPassword: 'scrypassword'
cacheEnabled: 'false'
adminEmail: 'garun@garunski.com'
adminPassword: 'test123'
task local:070-admin-install
Install API Directus
api-values.yaml
replicaCount: 1
image:
repository: directus/directus
pullPolicy: IfNotPresent
tag: "10.6"
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
serviceAccount:
create: true
annotations: {}
name: ""
podAnnotations: {}
podSecurityContext: {}
securityContext: {}
service:
type: ClusterIP
port: 8075
ingress:
create: false
gatewayApi:
create: true
host: api.local.scryapp.website
gateway:
create: false
name: 'scry-gw'
namespace: 'default'
route:
matches:
- path:
type: PathPrefix
value: /items
resources: {}
autoscaling:
enabled: false
env:
publicUrl: 'http://api.local.scryapp.website'
key: 'BB1AFE70-F462-4C98-9935-6902EADA57A5'
secret: 'EF222AE9-10FB-4190-AD4C-C6E866D19EF2'
dbClient: 'pg'
dbHost: 'postgres-postgresql-hl.default.svc.cluster.local'
dbPort: '5432'
dbDatabase: 'scry'
dbUser: 'scryuser'
dbPassword: 'scrypassword'
cacheEnabled: 'false'
extraEnvVars:
- name: SERVE_APP
value: "false"
task local:080-api-install
add gateway to Hosts
task local:090-update-hosts