ci: add workflow to publish runner image to docker hub
This commit is contained in:
39
.gitea/workflows/publish-runner.yml
Normal file
39
.gitea/workflows/publish-runner.yml
Normal file
@@ -0,0 +1,39 @@
|
||||
name: Publish Runner Image
|
||||
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- 'docker/runner/**'
|
||||
- '.gitea/workflows/publish-runner.yml'
|
||||
branches:
|
||||
- main
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v2
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@v4
|
||||
with:
|
||||
context: ./docker/runner
|
||||
file: ./docker/runner/Dockerfile
|
||||
push: true
|
||||
tags: ${{ secrets.DOCKER_USERNAME }}/vibetorrent-runner:latest
|
||||
platforms: linux/amd64,linux/arm64
|
||||
Reference in New Issue
Block a user