From 9fc2054e36979e483d7a4edc3dc4144783d82d66 Mon Sep 17 00:00:00 2001 From: Admin Date: Sun, 8 Mar 2026 22:39:16 +0500 Subject: [PATCH] ci: disable deploy workflow and add Docker Hub push to ui and scraper CI --- .gitea/workflows/ci-scraper.yaml | 24 +++++++++++++++++++ .gitea/workflows/ci-ui.yaml | 24 +++++++++++++++++++ .../{deploy.yaml => deploy.yaml.disabled} | 0 3 files changed, 48 insertions(+) rename .gitea/workflows/{deploy.yaml => deploy.yaml.disabled} (100%) diff --git a/.gitea/workflows/ci-scraper.yaml b/.gitea/workflows/ci-scraper.yaml index f0156c3..c17b175 100644 --- a/.gitea/workflows/ci-scraper.yaml +++ b/.gitea/workflows/ci-scraper.yaml @@ -82,3 +82,27 @@ jobs: name: scraper-linux-amd64 path: scraper/bin/scraper retention-days: 7 + + # ── push to Docker Hub ─────────────────────────────────────────────────────── + docker: + name: Docker Push + runs-on: ubuntu-latest + needs: build + if: gitea.event_name == 'push' + steps: + - uses: actions/checkout@v4 + + - name: Log in to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKER_USER }} + password: ${{ secrets.DOCKER_TOKEN }} + + - name: Build and push + uses: docker/build-push-action@v6 + with: + context: scraper + push: true + tags: | + ${{ secrets.DOCKER_USER }}/libnovel-scraper:latest + ${{ secrets.DOCKER_USER }}/libnovel-scraper:${{ gitea.sha }} diff --git a/.gitea/workflows/ci-ui.yaml b/.gitea/workflows/ci-ui.yaml index f6e59f4..a8b021a 100644 --- a/.gitea/workflows/ci-ui.yaml +++ b/.gitea/workflows/ci-ui.yaml @@ -43,3 +43,27 @@ jobs: - name: Build run: just ui-build + + # ── push to Docker Hub ─────────────────────────────────────────────────────── + docker: + name: Docker Push + runs-on: ubuntu-latest + needs: build + if: gitea.event_name == 'push' + steps: + - uses: actions/checkout@v4 + + - name: Log in to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKER_USER }} + password: ${{ secrets.DOCKER_TOKEN }} + + - name: Build and push + uses: docker/build-push-action@v6 + with: + context: ui + push: true + tags: | + ${{ secrets.DOCKER_USER }}/libnovel-ui:latest + ${{ secrets.DOCKER_USER }}/libnovel-ui:${{ gitea.sha }} diff --git a/.gitea/workflows/deploy.yaml b/.gitea/workflows/deploy.yaml.disabled similarity index 100% rename from .gitea/workflows/deploy.yaml rename to .gitea/workflows/deploy.yaml.disabled