feat: add Zod validation schemas for user, project, document, and cat… #8
This file contains hidden or 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: Build and Publish Image | |
| on: | |
| push: | |
| branches: | |
| - dev | |
| env: | |
| CONTEXT_PATH: . | |
| DOCKER_PATH: ./Dockerfile | |
| DOCKER_REPO: teamA | |
| IMAGE_NAME: be | |
| jobs: | |
| publish: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v3 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v2 | |
| - name: Docker login | |
| run: | | |
| echo ${{ secrets.DOCKER_TOKEN }} | docker login -u ${{ secrets.DOCKER_USERNAME }} --password-stdin | |
| - name: Docker meta | |
| id: meta | |
| uses: docker/metadata-action@v4 | |
| with: | |
| images: | | |
| "${{secrets.DOCKER_USERNAME}}/${{ env.DOCKER_REPO }}/${{ env.IMAGE_NAME }}" | |
| tags: | | |
| type=raw,value={{branch}}-sha-{{sha}} | |
| - name: Docker build | |
| run: | | |
| docker build -t ${{ steps.meta.outputs.images }}:${{ steps.meta.outputs.tags }} . | |
| - name: Docker push | |
| run: | | |
| docker push ${{ steps.meta.outputs.images }}:${{ steps.meta.outputs.tags }} | |