Build and publish Directus CMS #10
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: Build and publish Directus CMS | |
on: workflow_dispatch | |
jobs: | |
build_and_push: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout the repo | |
uses: actions/checkout@v2 | |
- name: Build image | |
run: docker build -t programmierbar/cms -f Dockerfile.directus . | |
- name: Install doctl | |
uses: digitalocean/action-doctl@v2 | |
with: | |
token: ${{ secrets.DIGITALOCEAN_ACCESS_TOKEN }} | |
- name: Log in to DO Container Registry | |
run: doctl registry login --expiry-seconds 600 | |
- name: Tag image | |
run: docker tag programmierbar/cms registry.digitalocean.com/programmierbar/cms:latest | |
- name: Push image to DO Container Registry | |
run: docker push registry.digitalocean.com/programmierbar/cms:latest |