2021-01-24 08:24:37 -06:00
|
|
|
name: Docker
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
2024-05-02 10:22:04 -04:00
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
paths-ignore:
|
|
|
|
- web/**
|
|
|
|
- doc/**
|
|
|
|
|
|
|
|
pull_request:
|
2021-01-24 08:24:37 -06:00
|
|
|
branches:
|
|
|
|
- main
|
2023-03-04 12:11:04 -05:00
|
|
|
paths-ignore:
|
|
|
|
- web/**
|
|
|
|
- doc/**
|
2021-01-24 08:24:37 -06:00
|
|
|
|
|
|
|
# Publish `v1.2.3` tags as releases.
|
|
|
|
tags:
|
|
|
|
- v*
|
|
|
|
|
2022-10-13 15:32:01 -05:00
|
|
|
concurrency:
|
|
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
|
|
cancel-in-progress: true
|
|
|
|
|
2021-01-24 08:24:37 -06:00
|
|
|
jobs:
|
2024-05-02 13:22:30 -04:00
|
|
|
docker-buildx:
|
2024-05-30 09:20:54 -04:00
|
|
|
env:
|
|
|
|
IMAGE_NAME: conky
|
|
|
|
DOCKER_BUILDKIT: 1
|
2024-06-04 14:00:29 -04:00
|
|
|
DOCKERHUB_USERNAME: brndnmtthws
|
|
|
|
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
|
2021-01-24 08:24:37 -06:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-09-04 17:18:19 +00:00
|
|
|
uses: actions/checkout@v4
|
2021-01-24 08:24:37 -06:00
|
|
|
- name: Set up QEMU
|
2023-09-18 17:55:27 +00:00
|
|
|
uses: docker/setup-qemu-action@v3
|
2021-01-24 08:24:37 -06:00
|
|
|
- name: Set up Docker Buildx
|
|
|
|
id: buildx
|
2023-09-18 17:55:23 +00:00
|
|
|
uses: docker/setup-buildx-action@v3
|
2024-05-13 14:13:38 -04:00
|
|
|
- name: Login to Docker Hub
|
|
|
|
uses: docker/login-action@v3
|
2024-06-04 14:00:29 -04:00
|
|
|
if: ${{ env.DOCKERHUB_TOKEN != '' }}
|
2024-05-13 14:13:38 -04:00
|
|
|
with:
|
2024-06-04 14:13:30 -04:00
|
|
|
username: ${{ env.DOCKERHUB_USERNAME }}
|
2024-05-13 14:13:38 -04:00
|
|
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
2024-05-02 13:22:30 -04:00
|
|
|
- name: Build and push Docker image
|
|
|
|
env:
|
|
|
|
RELEASE: "${{ startsWith(github.ref, 'refs/tags/') && 'ON' || 'OFF' }}"
|
2024-05-02 14:54:11 -04:00
|
|
|
GITHUB_REF: ${{ github.ref }}
|
2024-06-04 14:00:29 -04:00
|
|
|
run: .github/scripts/docker-build.bash
|