aboutsummaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorXe Iaso <me@xeiaso.net>2024-11-09 10:50:59 -0500
committerGitHub <noreply@github.com>2024-11-09 10:50:59 -0500
commit20d07c7005665f8e2001b4cbd24e15ec589d9882 (patch)
tree8b98d1446c6d9e42bc2621e633543e0420f43541 /.github
parent2b349f56cb20420dd153f40f22b3654b5079100f (diff)
downloadxesite-20d07c7005665f8e2001b4cbd24e15ec589d9882.tar.xz
xesite-20d07c7005665f8e2001b4cbd24e15ec589d9882.zip
Move to Kubernetes (#853)
* start to lift-and-shift to k8s Signed-off-by: Xe Iaso <me@xeiaso.net> * manifest/xesite: properly configure pod disruption budget, hostmount for xesite as a hack Signed-off-by: Xe Iaso <me@xeiaso.net> * properly slonk readiness Signed-off-by: Xe Iaso <me@xeiaso.net> * manifest: move to aeacus Signed-off-by: Xe Iaso <me@xeiaso.net> * internal: add OnionLocation middleware Signed-off-by: Xe Iaso <me@xeiaso.net> * internal/lume: jettison serving from the zipfile Signed-off-by: Xe Iaso <me@xeiaso.net> * yolo deploy to prod Signed-off-by: Xe Iaso <me@xeiaso.net> * okay use a machineproxy here Signed-off-by: Xe Iaso <me@xeiaso.net> * test CI/CD Signed-off-by: Xe Iaso <me@xeiaso.net> * try civo route Signed-off-by: Xe Iaso <me@xeiaso.net> * lol Signed-off-by: Xe Iaso <me@xeiaso.net> * plan c? Signed-off-by: Xe Iaso <me@xeiaso.net> * specify the region Signed-off-by: Xe Iaso <me@xeiaso.net> * lol Signed-off-by: Xe Iaso <me@xeiaso.net> * blog: hello again kubernetes! Signed-off-by: Xe Iaso <me@xeiaso.net> --------- Signed-off-by: Xe Iaso <me@xeiaso.net>
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/earthly.yml52
1 files changed, 19 insertions, 33 deletions
diff --git a/.github/workflows/earthly.yml b/.github/workflows/earthly.yml
index acde1a5..72a076b 100644
--- a/.github/workflows/earthly.yml
+++ b/.github/workflows/earthly.yml
@@ -46,34 +46,8 @@ jobs:
id: build
run: |
earthly --org me-2625 --sat alpha --ci +all
-
- deploy-patreon:
- name: "Deploy patreon-saasproxy"
- needs: build
- runs-on: ubuntu-latest
- permissions:
- contents: read
- if: github.ref == 'refs/heads/main'
-
- steps:
- - uses: actions/checkout@v4
- - uses: superfly/flyctl-actions/setup-flyctl@master
- - uses: dorny/paths-filter@v3
- id: changes
- with:
- filters: |
- src:
- - 'cmd/patreon-saasproxy/*.go'
- - 'internal/**/*.go'
- - 'go.mod'
- - 'go.sum'
- - 'Earthfile'
- - if: steps.changes.outputs.src == 'true'
- run: flyctl deploy --remote-only -c ./fly/patreon-saasproxy/fly.toml
- env:
- FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}
- deploy-xesite:
+ deploy:
name: "Deploy xesite"
needs: build
runs-on: ubuntu-latest
@@ -83,18 +57,30 @@ jobs:
steps:
- uses: actions/checkout@v4
- - uses: superfly/flyctl-actions/setup-flyctl@master
+ - uses: azure/setup-kubectl@v4
+ - name: Save Civo kubeconfig
+ run: |
+ curl -sL https://civo.com/get | sh
+ civo apikey add default $CIVO_TOKEN
+ civo apikey current default
+ civo kubernetes config --region phx1 aeacus --save --switch
+ env:
+ CIVO_TOKEN: ${{ secrets.CIVO_TOKEN }}
- uses: dorny/paths-filter@v3
id: changes
with:
filters: |
src:
- - 'cmd/xesite/*.go'
+ - 'cmd/**/*.go'
- 'internal/**/*.go'
+ - 'pb/*'
+ - 'pb/**/*'
- 'go.mod'
- 'go.sum'
- 'Earthfile'
- - if: steps.changes.outputs.src == 'true'
- run: flyctl deploy --remote-only -c ./fly/xesite/fly.toml
- env:
- FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}
+ - 'manifest/**/*.yaml'
+ - name: "Deploy"
+ if: steps.changes.outputs.src == 'true'
+ run: |
+ kubectl apply -k manifest
+ kubectl rollout restart -n default deploy/xesite