fix build #28
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deployment | |
concurrency: | |
group: swytch-once-deployment | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
deploy: | |
timeout-minutes: 15 | |
name: Deploy to Production | |
runs-on: self-hosted | |
environment: Production | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Docker Login | |
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin | |
- name: Set up Docker Buildx | |
id: buildx | |
uses: docker/setup-buildx-action@master | |
with: | |
install: true | |
- name: Install DevSpace | |
uses: loft-sh/setup-devspace@main | |
- name: configure context | |
run: | | |
mkdir -p ~/.kube | |
echo "${{ secrets.KUBECONFIG }}" > ~/.kube/config | |
- name: Switch to namespace | |
run: loft use cluster && devspace use namespace once | |
- name: Execute | |
run: | | |
devspace build -t ${{ github.sha }} --no-warn | |
- name: Deploy | |
run: | | |
devspace deploy --no-warn -t ${{ github.sha }} --skip-dependency auth \ | |
--var STATE_SECRET="${{ secrets.STATE_SECRET }}" \ | |
--var RETHINKDB_PASSWORD="${{ secrets.RETHINKDB_PASSWORD }}" \ | |
--var RETHINKDB_USER='once' \ | |
--var HOST="once.getswytch.com" |