2025-01-17 10:30:27 +01:00
|
|
|
name: functions
|
|
|
|
|
|
|
|
on:
|
|
|
|
- push
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Setup `spin`
|
|
|
|
uses: fermyon/actions/spin/setup@v1
|
|
|
|
|
2025-01-17 11:03:10 +01:00
|
|
|
- name: Setup tinygo
|
|
|
|
uses: acifani/setup-tinygo@v2
|
|
|
|
with:
|
|
|
|
tinygo-version: "0.35.0"
|
|
|
|
install-binaryen: "false"
|
|
|
|
|
2025-01-17 10:30:27 +01:00
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
|
|
|
|
- name: Build
|
|
|
|
run: |
|
|
|
|
spin registry push --build code.icb4dc0.de/infrastructure/functions/comics
|
|
|
|
working-directory: comics
|
|
|
|
|
|
|
|
- name: Deploy
|
2025-01-17 11:03:10 +01:00
|
|
|
uses: clowdhaus/argo-cd-action@v2.2.0
|
2025-01-17 10:30:27 +01:00
|
|
|
with:
|
|
|
|
command: app create functions
|
|
|
|
options: -f deploy/argo-app.yaml --upsert --server argo-cd-argocd-server.argo-system.svc --auth-token ${{ secrets.ARGOCD_TOKEN }} --plaintext
|
|
|
|
version: "2.13.3"
|
|
|
|
|
|
|
|
- name: Deploy
|
2025-01-17 11:03:10 +01:00
|
|
|
uses: clowdhaus/argo-cd-action@v2.2.0
|
2025-01-17 10:30:27 +01:00
|
|
|
with:
|
|
|
|
command: app sync functions
|
|
|
|
options: --assumeYes --server argo-cd-argocd-server.argo-system.svc --auth-token ${{ secrets.ARGOCD_TOKEN }} --plaintext
|