add some common extensions, fixes #52 #1473
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 Docker Images | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
workflow_dispatch: | |
schedule: | |
- cron: "0 0 * * *" | |
env: | |
DO_PUSH: ${{ github.ref == 'refs/heads/main' }} # do not push on PRs | |
jobs: | |
images: | |
timeout-minutes: 60 | |
runs-on: ubuntu-latest | |
steps: | |
- name: checkout sources | |
uses: actions/checkout@v4 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
id: buildx | |
with: | |
install: true | |
- name: Docker rt meta | |
id: meta | |
uses: docker/metadata-action@v5 | |
with: | |
images: firefart/requesttracker | |
tags: | | |
# set latest tag for default branch | |
type=raw,value=latest,enable={{is_default_branch}} | |
# set rt version | |
type=raw,value=5.0.7,enable=true | |
# make a sha tag | |
type=sha,enable=true,priority=100,prefix=sha-,suffix=,format=short | |
type=schedule,pattern={{date 'YYYYMMDD'}},prefix=nightly- | |
- name: Login to Docker Hub | |
uses: docker/[email protected] | |
if: env.DO_PUSH == 'true' | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Build and push RT | |
uses: docker/build-push-action@v6 | |
with: | |
push: ${{ env.DO_PUSH }} | |
#platforms: linux/amd64,linux/arm/v7,linux/arm64 | |
tags: ${{ steps.meta.outputs.tags }} | |
labels: ${{ steps.meta.outputs.labels }} |