Docker CI #525
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
### This file provides a template for creating a GitHub Actions Workflow, | |
### that implements ci for a Docker Image. | |
name: Docker CI | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- main | |
- develop | |
# Build then a new version is tagged | |
tags: | |
- '*.*.*' | |
pull_request: | |
branches: | |
- main | |
- develop | |
schedule: | |
# Build every night at 1am | |
- cron: '0 1 * * *' | |
jobs: | |
build: | |
# This workflow defines how a maven package is built, tested and published. | |
# Visit: https://github.com/samply/github-workflows/blob/develop/.github/workflows/maven-ci.yml, for more information | |
uses: samply/github-workflows/.github/workflows/docker-ci.yml@main | |
with: | |
# The Docker Hub Repository you want eventually push to, e.g samply/share-client | |
image-name: "samply/bridgehead-forward-proxy" | |
# Define special prefixes for docker tags. They will prefix each images tag. | |
# image-tag-prefix: "foo" | |
# Define the build context of your image, typically default '.' will be enough | |
# build-context: '.' | |
# Define the Dockerfile of your image, typically default './Dockerfile' will be enough | |
# build-file: './Dockerfile' | |
# A list of build arguments, passed to the docker build | |
# build-args: | | |
# foo: bar | |
# If your actions generate an artifact in a previous build step, you can tell this workflow to download it | |
# artifact-name: '' # the default '' doesn't try to download an artifact | |
push-to: dockerhub | |
# This passes the secrets from calling workflow to the called workflow | |
secrets: | |
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }} | |
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }} |