Skip to content

Commit

Permalink
chore: minor kube justfile changes
Browse files Browse the repository at this point in the history
  • Loading branch information
stuartwdouglas committed Nov 3, 2024
1 parent 65a66c1 commit 6b7b3d8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
5 changes: 3 additions & 2 deletions deployment/Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,15 @@ setup-registry:

setup-cluster: setup-registry
#!/bin/bash
bash -c "cd ../ && just chart dep-update"
if [ -z "$(k3d cluster list | grep ftl)" ]; then
k3d cluster create ftl --api-port 6550 -p "8892:80@loadbalancer" -p "8891:80@loadbalancer" -p "8893:80@loadbalancer" --agents 2 \
--registry-use {{registry_full}} \
--registry-config '{{mirrors}}'
fi
kubectl config set-context --current --namespace=default

install-istio: setup-cluster
setup-istio-cluster: setup-cluster
#!/bin/bash
if [ -z "$(kubectl get namespace | grep istio-system)" ]; then
kubectl create namespace istio-system
Expand All @@ -72,7 +73,7 @@ apply:
kubectl delete job --ignore-not-found=true ftl-dbmig-latest
helm upgrade --install ftl ../charts/ftl -f values.yaml

deploy-version version: setup-cluster install-istio
deploy-version version: setup-istio-cluster
helm repo add ftl https://tbd54566975.github.io/ftl-charts --force-update
helm upgrade --install ftl ftl/ftl --version={{version}} -f values-release.yaml || sleep 5 # wait for CRDs to be created, the initial apply will usually fail
helm upgrade --install ftl ftl/ftl --version={{version}} -f values-release.yaml
Expand Down
6 changes: 1 addition & 5 deletions internal/integration/harness.go
Original file line number Diff line number Diff line change
Expand Up @@ -230,11 +230,7 @@ func run(t *testing.T, actionsOrOptions ...ActionOrOption) {
if opts.kube {
// This command will build a linux/amd64 version of FTL and deploy it to the kube cluster
Infof("Building FTL and deploying to kube")
err = ftlexec.Command(ctx, log.Debug, rootDir, "just", "chart", "dep-update").RunBuffered(ctx)
assert.NoError(t, err)
err = ftlexec.Command(ctx, log.Debug, filepath.Join(rootDir, "deployment"), "just", "setup-cluster").RunBuffered(ctx)
assert.NoError(t, err)
err = ftlexec.Command(ctx, log.Debug, filepath.Join(rootDir, "deployment"), "just", "install-istio").RunBuffered(ctx)
err = ftlexec.Command(ctx, log.Debug, filepath.Join(rootDir, "deployment"), "just", "setup-istio-cluster").RunBuffered(ctx)
assert.NoError(t, err)

skipKubeFullDeploy := os.Getenv("SKIP_KUBE_FULL_DEPLOY") == "true"
Expand Down

0 comments on commit 6b7b3d8

Please sign in to comment.