Skip to content

fix(backend): type-invalid error handling #49

fix(backend): type-invalid error handling

fix(backend): type-invalid error handling #49

Workflow file for this run

name: cicd
on:
push:
branches:
- development
- master
jobs:
build:
runs-on: ubuntu-20.04
env:
SKAFFOLD_DEFAULT_REPO: ghcr.io/con2
steps:
- uses: actions/checkout@v1
- uses: actions/setup-python@v2
with:
python-version: '3.x'
- uses: pairity/setup-cd-tools@30acb848f9ff747aff4810dac40c5cc0971f485d
with:
skaffold: '1.20.0'
- uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ secrets.GHCR_USERNAME }}
password: ${{ secrets.GHCR_PASSWORD }}
- uses: docker/setup-buildx-action@v1
- id: build
run: |
python3 -m pip install emskaffolden
emskaffolden -E staging -- build --file-output build.json
echo "::set-output name=build_json::$(base64 -w 0 < build.json)"
outputs:
build_json: ${{ steps.build.outputs.build_json }}
# TODO DRY
deploy_staging:
runs-on: self-hosted
needs: build
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/development' }}
steps:
- uses: actions/checkout@v1
- uses: actions/setup-python@v2
with:
python-version: '3.x'
- uses: pairity/setup-cd-tools@30acb848f9ff747aff4810dac40c5cc0971f485d
with:
kubectl: '1.20.4'
skaffold: '1.20.0'
- uses: docker/setup-buildx-action@v1
- run: |
python3 -m pip install emskaffolden
base64 -d <<< "${{ needs.build.outputs.build_json }}" > build.json
emskaffolden -E staging -- deploy -n conikuvat-staging -a build.json
deploy_conikuvat:
runs-on: self-hosted
needs: build
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
steps:
- uses: actions/checkout@v1
- uses: actions/setup-python@v2
with:
python-version: '3.x'
- uses: pairity/setup-cd-tools@30acb848f9ff747aff4810dac40c5cc0971f485d
with:
kubectl: '1.20.4'
skaffold: '1.20.0'
- uses: docker/setup-buildx-action@v1
- run: |
python3 -m pip install emskaffolden
base64 -d <<< "${{ needs.build.outputs.build_json }}" > build.json
emskaffolden -E production -- deploy -n conikuvat-production -a build.json
deploy_larppikuvat:
runs-on: self-hosted
needs: build
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
steps:
- uses: actions/checkout@v1
- uses: actions/setup-python@v2
with:
python-version: '3.x'
- uses: pairity/setup-cd-tools@30acb848f9ff747aff4810dac40c5cc0971f485d
with:
kubectl: '1.20.4'
skaffold: '1.20.0'
- uses: docker/setup-buildx-action@v1
- run: |
python3 -m pip install emskaffolden
base64 -d <<< "${{ needs.build.outputs.build_json }}" > build.json
emskaffolden -E larppikuvat -- deploy -n larppikuvat -a build.json