Update docker-compose.postgres.yml (#165) #390
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: Continuous testing and deployment | |
on: | |
push: | |
branches-ignore: | |
- 'dependabot/**' | |
pull_request: | |
permissions: read-all | |
jobs: | |
test: | |
name: Run tests | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: Install goss and dgoss | |
uses: e1himself/goss-installation-action@v1.0.4 | |
with: | |
# Goss release version to install | |
version: 'v0.3.16' | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Build the Docker image | |
uses: docker/build-push-action@v3.2.0 | |
with: | |
push: false | |
tags: phanan/koel:test | |
- name: Run goss tests on the image | |
run: dgoss run phanan/koel:test | |
deploy: | |
name: Deploy to Docker Hub | |
runs-on: ubuntu-20.04 | |
needs: [test] | |
if: github.ref == 'refs/heads/master' && github.event_name == 'push' | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2.1.0 | |
id: qemu | |
with: | |
platforms: linux/amd64,linux/arm64,linux/arm/v7 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2.2.1 | |
- name: Login to DockerHub | |
uses: docker/login-action@v2.1.0 | |
with: | |
username: ${{ secrets.DOCKER_HUB_USERNAME }} | |
password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
- name: Build and push the production image | |
uses: docker/build-push-action@v3.2.0 | |
with: | |
push: true | |
tags: phanan/koel:latest,phanan/koel:6.12.1 | |
platforms: linux/amd64,linux/arm64,linux/arm/v7 |