Skip to content

Refactor/keycloak upgrade #89

Refactor/keycloak upgrade

Refactor/keycloak upgrade #89

Workflow file for this run

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# GitHub recommends pinning actions to a commit SHA.
# To get a newer version, you will need to update the SHA.
# You can also reference a tag or branch, but the action may change without warning.
name: Publish Docker image
on:
release:
types: [published]
push:
branches: [ "master" ]
# Publish semver tags as releases.
tags: [ 'v*.*.*' ]
pull_request:
branches: [ "master" ]
env:
# Use docker.io for Docker Hub if empty
REGISTRY: bibbox
# github.repository as <account>/<repo>
IMAGE_NAME_APACHE: bibbox-sys-commander-apacheproxy
IMAGE_NAME_BACKEND: bibbox-sys-commander-backend
IMAGE_NAME_DB: bibbox-sys-commander-postgres
jobs:
push_to_registry:
name: Push Docker image to Docker Hub
runs-on: ubuntu-22.04
steps:
- name: Check out the repo
uses: actions/checkout@v3
- name: Log in to Docker Hub
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Extract metadata (tags, labels) for apache Docker
id: meta-apache
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
with:
#images: my-docker-hub-namespace/my-docker-hub-repository
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME_APACHE }}
- name: Extract metadata (tags, labels) for backend Docker
id: meta-backend
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
with:
#images: my-docker-hub-namespace/my-docker-hub-repository
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME_BACKEND }}
- name: Extract metadata (tags, labels) for postgres Docker
id: meta-postgres
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
with:
#images: my-docker-hub-namespace/my-docker-hub-repository
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME_DB }}
- name: Build and push apache Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: ./apacheproxy/
push: true
tags: ${{ steps.meta-apache.outputs.tags }}
labels: ${{ steps.meta-apache.outputs.labels }}
- name: Build and push backend Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: ./backend/
push: true
tags: ${{ steps.meta-backend.outputs.tags }}
labels: ${{ steps.meta-backend.outputs.labels }}
- name: Build and push postgres Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: ./postgresql/
push: true
tags: ${{ steps.meta-postgres.outputs.tags }}
labels: ${{ steps.meta-postgres.outputs.labels }}