Skip to content

fix: add null validation on username #108

fix: add null validation on username

fix: add null validation on username #108

Workflow file for this run

name: Release
on:
push:
tags:
- "v*"
env:
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}
jobs:
test-api:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Test api
working-directory: api
run: make test
test-ui:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Test ui
run: |
docker compose -f docker-compose.test.yml build
docker compose -f docker-compose.test.yml up --abort-on-container-exit --exit-code-from e2e
build-api:
needs: test-api
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Log in to registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ secrets.CONTAINER_USERNAME }}
password: ${{ secrets.CONTAINER_PASSWORD }}
- name: Build and Push image
uses: docker/build-push-action@v5
with:
push: true
context: ./api
tags: ${{ secrets.REPOSITORY_NAME }}/planning-poker-api:${{ github.ref_name }}
build-ui:
needs: test-ui
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Log in to registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ secrets.CONTAINER_USERNAME }}
password: ${{ secrets.CONTAINER_PASSWORD }}
- name: Build and Push image
uses: docker/build-push-action@v5
with:
push: true
context: ./ui
tags: ${{ secrets.REPOSITORY_NAME }}/planning-poker-ui:${{ github.ref_name }}
deploy:
needs: [build-ui, build-api]
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Log in to registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ secrets.CONTAINER_USERNAME }}
password: ${{ secrets.CONTAINER_PASSWORD }}
- uses: superfly/flyctl-actions/setup-flyctl@master
- run: |
docker pull ${{ secrets.REPOSITORY_NAME }}/planning-poker-ui:${{ github.ref_name }}
docker pull ${{ secrets.REPOSITORY_NAME }}/planning-poker-api:${{ github.ref_name }}
- name: deploy ui
run: |
flyctl deploy --image ${{ secrets.REPOSITORY_NAME }}/planning-poker-ui:${{ github.ref_name }} \
--image-label ${{ github.ref_name }} \
--local-only ui
- name: deploy web-api
run: |
flyctl deploy --image ${{ secrets.REPOSITORY_NAME }}/planning-poker-api:${{ github.ref_name }} \
--image-label ${{ github.ref_name }} \
--local-only api