From de681046037db8401c37bc9d80d65e3c38315289 Mon Sep 17 00:00:00 2001 From: Firq Date: Sat, 20 Jul 2024 18:02:22 +0200 Subject: [PATCH] Re-integrate Dockge into preview workflow --- .forgejo/workflows/build_preview.yml | 54 ++++++++++++++-------------- .forgejo/workflows/test_dockge.yml | 31 ---------------- 2 files changed, 27 insertions(+), 58 deletions(-) delete mode 100644 .forgejo/workflows/test_dockge.yml diff --git a/.forgejo/workflows/build_preview.yml b/.forgejo/workflows/build_preview.yml index 86e7eec..0992b09 100644 --- a/.forgejo/workflows/build_preview.yml +++ b/.forgejo/workflows/build_preview.yml @@ -65,30 +65,30 @@ jobs: tag: ${{ github.ref_name }} prerelease: true - # auto-deploy-dockge: - # needs: [ build-site ] - # runs-on: docker - # if: success() - # container: nikolaik/python-nodejs:python3.11-nodejs21 - # steps: - # - name: Configure pip - # run: | - # pip config set global.index-url https://pypi.org/simple - # pip config set global.extra-index-url https://forgejo.neshweb.net/api/packages/Firq/pypi/simple/ - # pip config set global.timeout 60 - # pip config set global.trusted-host "pypi.org forgejo.neshweb.net" - # - name: Install Dockge CLI - # run: pip install dockge-cli - # - name: Configure Dockge CLI - # run: | - # dockge host https://dockge.firq.dev - # dockge login --user ${{ secrets.DOCKGE_USER }} --password ${{ secrets.DOCKGE_CREDENTIAL }} - # - name: Check status and redeploy - # run: | - # dockge status firq-dev-preview - # dockge update firq-dev-preview - # dockge status firq-dev-preview - # - name: Reset CLI - # run : | - # dockge logout - # dockge exit + auto-deploy-dockge: + needs: [ build-site ] + if: success() + runs-on: docker + container: nikolaik/python-nodejs:python3.11-nodejs21 + steps: + - name: Configure pip + run: | + pip config set global.index-url https://pypi.org/simple + pip config set global.extra-index-url https://forgejo.neshweb.net/api/packages/Firq/pypi/simple/ + pip config set global.timeout 60 + pip config set global.trusted-host "pypi.org forgejo.neshweb.net" + - name: Install Dockge CLI + run: pip install dockge-cli==0.1.1-c.1 + - name: Configure Dockge CLI + run: | + dockge host https://dockge.firq.dev + dockge login --user '${{ secrets.DOCKGE_USER }}' --password '${{ secrets.DOCKGE_CREDENTIAL }}' + - name: Check status and redeploy + run: | + dockge status firq-dev-preview + dockge update firq-dev-preview + dockge status firq-dev-preview + - name: Reset CLI + run : | + dockge logout + dockge exit diff --git a/.forgejo/workflows/test_dockge.yml b/.forgejo/workflows/test_dockge.yml deleted file mode 100644 index 3414867..0000000 --- a/.forgejo/workflows/test_dockge.yml +++ /dev/null @@ -1,31 +0,0 @@ -on: - push: - branches: - - '**' - -jobs: - auto-deploy-dockge: - runs-on: docker - container: nikolaik/python-nodejs:python3.11-nodejs21 - steps: - - name: Configure pip - run: | - pip config set global.index-url https://pypi.org/simple - pip config set global.extra-index-url https://forgejo.neshweb.net/api/packages/Firq/pypi/simple/ - pip config set global.timeout 60 - pip config set global.trusted-host "pypi.org forgejo.neshweb.net" - - name: Install Dockge CLI - run: pip install dockge-cli==0.1.1-c.1 - - name: Configure Dockge CLI - run: | - dockge host https://dockge.firq.dev - dockge login --user "${{ secrets.DOCKGE_USER }}" --password '${{ secrets.DOCKGE_CREDENTIAL }}' - - name: Check status and redeploy - run: | - dockge status firq-dev-preview - dockge update firq-dev-preview - dockge status firq-dev-preview - - name: Reset CLI - run : | - dockge logout - dockge exit