diff options
| author | Jan Tuomi <jan.tuomi@valuemotive.com> | 2021-11-04 13:34:02 +0200 |
|---|---|---|
| committer | Jan Tuomi <jan.tuomi@valuemotive.com> | 2021-11-04 13:34:02 +0200 |
| commit | 462b2fe10cf45da3dbcb5ee20ca6dfb79f46e6b6 (patch) | |
| tree | 2862938769f5c3e0efd57f5256dbdbb5452cdb4e /.github/workflows/jan-systems-website.yml | |
Initial commit
Diffstat (limited to '.github/workflows/jan-systems-website.yml')
| -rw-r--r-- | .github/workflows/jan-systems-website.yml | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/.github/workflows/jan-systems-website.yml b/.github/workflows/jan-systems-website.yml new file mode 100644 index 0000000..023a769 --- /dev/null +++ b/.github/workflows/jan-systems-website.yml @@ -0,0 +1,34 @@ +name: Deploy website to GCP + +on: + push: + branches: + - main + +env: + IMAGE: registry.digitalocean.com/jan-systems-registry/jan-systems-website:latest + DO_DOCKER_LOGIN: ${{ secrets.DO_DOCKER_LOGIN }} + +jobs: + website: + name: Build and Push + runs-on: ubuntu-latest + environment: + name: production + url: https://jan.systems + + steps: + - name: Checkout + uses: actions/checkout@v2 + + # Login to Digitalocean registry + - name: Log in to Digitalocean registry + run: docker login -u ${DO_DOCKER_LOGIN} -p ${DO_DOCKER_LOGIN} registry.digitalocean.com + + # Build the Docker image + - name: Build image + run: docker build -t ${IMAGE} . + + # Push the Docker image to Google Container Registry + - name: Push image to registry + run: docker push ${IMAGE} |
