feat: add GitHub Actions workflows for publishing backend and frontend Docker images
This commit is contained in:
@@ -1,13 +1,12 @@
|
|||||||
name: Publish Docker Images
|
name: Publish Backend Image
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [main]
|
branches: [main]
|
||||||
paths:
|
paths:
|
||||||
- 'qwen3-tts-backend/**'
|
- 'qwen3-tts-backend/**'
|
||||||
- 'qwen3-tts-frontend/**'
|
|
||||||
- 'qwen_tts/**'
|
- 'qwen_tts/**'
|
||||||
- 'docker/**'
|
- 'docker/backend/**'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-and-push:
|
build-and-push:
|
||||||
@@ -24,7 +23,7 @@ jobs:
|
|||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
- name: Build and push backend
|
- name: Build and push
|
||||||
uses: docker/build-push-action@v6
|
uses: docker/build-push-action@v6
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
@@ -33,13 +32,3 @@ jobs:
|
|||||||
tags: bdim404/qwen3-tts-backend:latest
|
tags: bdim404/qwen3-tts-backend:latest
|
||||||
cache-from: type=gha,scope=backend
|
cache-from: type=gha,scope=backend
|
||||||
cache-to: type=gha,mode=max,scope=backend
|
cache-to: type=gha,mode=max,scope=backend
|
||||||
|
|
||||||
- name: Build and push frontend
|
|
||||||
uses: docker/build-push-action@v6
|
|
||||||
with:
|
|
||||||
context: .
|
|
||||||
file: docker/frontend/Dockerfile
|
|
||||||
push: true
|
|
||||||
tags: bdim404/qwen3-tts-frontend:latest
|
|
||||||
cache-from: type=gha,scope=frontend
|
|
||||||
cache-to: type=gha,mode=max,scope=frontend
|
|
||||||
33
.github/workflows/docker-frontend.yml
vendored
Normal file
33
.github/workflows/docker-frontend.yml
vendored
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
name: Publish Frontend Image
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [main]
|
||||||
|
paths:
|
||||||
|
- 'qwen3-tts-frontend/**'
|
||||||
|
- 'docker/frontend/**'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-and-push:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Log in to Docker Hub
|
||||||
|
uses: docker/login-action@v3
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
|
- name: Build and push
|
||||||
|
uses: docker/build-push-action@v6
|
||||||
|
with:
|
||||||
|
context: .
|
||||||
|
file: docker/frontend/Dockerfile
|
||||||
|
push: true
|
||||||
|
tags: bdim404/qwen3-tts-frontend:latest
|
||||||
|
cache-from: type=gha,scope=frontend
|
||||||
|
cache-to: type=gha,mode=max,scope=frontend
|
||||||
Reference in New Issue
Block a user