4.0.0-rc.10 #33
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: Deploy to ALPHA environment | |
on: | |
push: | |
branches: | |
- feature/new-backend | |
jobs: | |
build: | |
name: Build and Push Docker Image | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout the updated source code | |
uses: actions/checkout@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Login to container registry | |
uses: docker/login-action@v2 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build image and push it to the container registry | |
uses: docker/build-push-action@v4 | |
with: | |
build-args: NG_CONFIGURATION=production | |
push: true | |
context: . | |
tags: "ghcr.io/bosancz/interni-sekce:alpha" | |
cache-from: type=gha | |
cache-to: type=gha,mode=max | |
deploy: | |
name: Deploy to ALPHA environment | |
needs: build | |
runs-on: ubuntu-latest # Run the job on an Ubuntu runner | |
steps: | |
- name: Call Watchtower to Update Docker Image | |
run: | | |
curl -I --fail-with-body \ | |
-H "Authorization: Bearer ${{ secrets.WATCHTOWER_TOKEN }}" \ | |
${{ vars.WATCHTOWER_URL }} |