testing new workflow
Some checks failed
Docker Image CI / build-and-push-image (push) Has been cancelled
Some checks failed
Docker Image CI / build-and-push-image (push) Has been cancelled
This commit is contained in:
@@ -1,15 +1,18 @@
|
|||||||
name: Build and Push Docker Image
|
name: Docker Image CI
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- "main"
|
||||||
- develop
|
tags:
|
||||||
pull_request:
|
- "*" # This triggers the workflow on any tag push
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build-and-push-image:
|
||||||
runs-on: prodesk
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: catthehacker/ubuntu:act-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
@@ -17,19 +20,34 @@ jobs:
|
|||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
- name: Log in to Gitea Docker Registry
|
- name: Log in to the Container registry
|
||||||
uses: docker/login-action@v3
|
uses: docker/login-action@v3
|
||||||
with:
|
with:
|
||||||
registry: gitea.calahilstudios.com
|
registry: gitea.calahilstudios.com
|
||||||
username: ${{ secrets.REGISTRY_USER }}
|
username: ${{ secrets.REGISTRY_USER }}
|
||||||
password: ${{ secrets.REGISTRY_TOKEN }}
|
password: ${{ secrets.REGISTRY_TOKEN }}
|
||||||
|
|
||||||
- name: Build and push image
|
- name: Prepare tags
|
||||||
uses: docker/build-push-action@v6
|
id: prepare_tags
|
||||||
|
run: |
|
||||||
|
# The image reference for your Gitea registry
|
||||||
|
IMAGE_REF=gitea.calahilstudios.com/calahil/backupbot
|
||||||
|
|
||||||
|
# The main tags: latest and commit SHA
|
||||||
|
TAGS="${IMAGE_REF}:latest,${IMAGE_REF}:${{ gitea.sha }}"
|
||||||
|
|
||||||
|
# If the event is a tag push, add the git tag as a tag
|
||||||
|
if [[ "${{ gitea.ref_type }}" == "tag" ]]; then
|
||||||
|
GIT_TAG_NAME=$(basename "${{ gitea.ref }}")
|
||||||
|
TAGS="${TAGS},${IMAGE_REF}:${GIT_TAG_NAME}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set the tags as a step output
|
||||||
|
echo "DOCKER_TAGS=${TAGS}" >> $GITEA_ENV
|
||||||
|
|
||||||
|
- name: Build and push Docker image
|
||||||
|
uses: docker/build-push-action@v5
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
file: ./Dockerfile
|
|
||||||
push: true
|
push: true
|
||||||
tags: |
|
tags: ${{ steps.prepare_tags.outputs.DOCKER_TAGS }}
|
||||||
gitea.calahilstudios.com/${{ github.repository_owner }}/${{ github.event.repository.name }}:develop
|
|
||||||
gitea.calahilstudios.com/${{ github.repository_owner }}/${{ github.event.repository.name }}:${{ github.sha }}
|
|
||||||
|
|||||||
12
README.md
12
README.md
@@ -2,18 +2,12 @@
|
|||||||
|
|
||||||
[](https://www.gnu.org/licenses/agpl-3.0)
|
[](https://www.gnu.org/licenses/agpl-3.0)
|
||||||
[](https://www.docker.com/)
|
[](https://www.docker.com/)
|
||||||
[](https://gitea.calahilstudios.com/calahil/backupbot)
|
|
||||||
[](https://gitea.calahilstudios.com)
|
[](https://gitea.calahilstudios.com)
|
||||||
[](https://scarf.sh)
|

|
||||||
[](https://gitea.calahilstudios.com/calahil/backupbot)
|

|
||||||
[](https://github.com/linuxserver/docker-duplicati/releases)
|
|
||||||
[](https://github.com/linuxserver/docker-duplicati/packages)
|
|
||||||
[](https://gitlab.com/linuxserver.io/docker-duplicati/container_registry)
|
|
||||||
[](https://quay.io/repository/linuxserver.io/duplicati)
|
|
||||||
[](https://hub.docker.com/r/linuxserver/duplicati)
|
[](https://hub.docker.com/r/linuxserver/duplicati)
|
||||||
[](https://hub.docker.com/r/linuxserver/duplicati)
|
[](https://hub.docker.com/r/linuxserver/duplicati)
|
||||||
[](https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-duplicati/job/master/)
|
|
||||||
[](https://ci-tests.linuxserver.io/linuxserver/duplicati/latest/index.html)
|
|
||||||
|
|
||||||
> **Automated Docker backup system for PostgreSQL databases and application configurations with Duplicati integration**
|
> **Automated Docker backup system for PostgreSQL databases and application configurations with Duplicati integration**
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user