wip #3
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: PR pipeline | |
| on: | |
| pull_request: | |
| branches: | |
| - develop | |
| env: | |
| IMAGE_NAME: hsldevcom/hsl-map-server | |
| TEST_STAGE: tester | |
| jobs: | |
| build-check-test: | |
| name: Build, check, test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| clean: 'true' | |
| fetch-depth: 2 | |
| - name: Lowercase Docker Image Name | |
| run: echo "IMAGE_NAME=${IMAGE_NAME,,}" >> "${GITHUB_ENV}" | |
| - name: Setup Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Build tester image | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| load: true | |
| target: "${{ env.TEST_STAGE }}" | |
| tags: "${{ env.IMAGE_NAME }}:${{ env.TEST_STAGE }}" | |
| - name: Run checks and tests inside Docker | |
| run: docker run --rm "${{ env.IMAGE_NAME }}:${{ env.TEST_STAGE }}" |