From b55ddfe6e44c674fa7d77f86d76d6835838323ed Mon Sep 17 00:00:00 2001 From: Richie Permana Date: Sat, 22 Nov 2025 00:08:43 +0800 Subject: [PATCH 1/5] cicd: debug --- .github/workflows/deploy-docs.yml | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml index 8411f8d..cfb15d7 100644 --- a/.github/workflows/deploy-docs.yml +++ b/.github/workflows/deploy-docs.yml @@ -1,7 +1,8 @@ name: Deploy Docs on: - push: + # push: + pull_request: branches: [main] permissions: @@ -46,18 +47,22 @@ jobs: run: pnpm build working-directory: apps/docs + - name: Verify build output + run: ls -R apps/docs/.vitepress/dist + - name: Upload artifact uses: actions/upload-pages-artifact@v3 with: path: apps/docs/.vitepress/dist deploy: + name: Deploy + needs: build + runs-on: ubuntu-latest environment: name: github-pages url: ${{ steps.deployment.outputs.page_url }} - needs: build - runs-on: ubuntu-latest - name: Deploy + steps: - name: Deploy to GitHub Pages id: deployment From c589e39456e1acacb5de1c7112190f93fb7f918e Mon Sep 17 00:00:00 2001 From: Richie Permana Date: Sat, 22 Nov 2025 00:10:19 +0800 Subject: [PATCH 2/5] cicd: debug --- .github/workflows/deploy-docs.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml index cfb15d7..3fb93e8 100644 --- a/.github/workflows/deploy-docs.yml +++ b/.github/workflows/deploy-docs.yml @@ -64,6 +64,9 @@ jobs: url: ${{ steps.deployment.outputs.page_url }} steps: + - name: Verify build output + run: ls -R apps/docs/.vitepress/dist + - name: Deploy to GitHub Pages id: deployment uses: actions/deploy-pages@v4 From 177f3c6586cf43756663353bb8f0f6bd08ea5770 Mon Sep 17 00:00:00 2001 From: Richie Permana Date: Sat, 22 Nov 2025 00:11:00 +0800 Subject: [PATCH 3/5] cicd: debug --- .github/workflows/deploy-docs.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml index 3fb93e8..9e05e5c 100644 --- a/.github/workflows/deploy-docs.yml +++ b/.github/workflows/deploy-docs.yml @@ -1,9 +1,9 @@ name: Deploy Docs on: - # push: - pull_request: - branches: [main] + push: + # branches: [main] + branches: [development] permissions: contents: read From 3d03d9780c88a4b00984b3b6033b498e4c664513 Mon Sep 17 00:00:00 2001 From: Richie Permana Date: Sat, 22 Nov 2025 00:19:37 +0800 Subject: [PATCH 4/5] cicd: debug --- .github/workflows/deploy-docs.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml index 9e05e5c..94c53ef 100644 --- a/.github/workflows/deploy-docs.yml +++ b/.github/workflows/deploy-docs.yml @@ -64,8 +64,8 @@ jobs: url: ${{ steps.deployment.outputs.page_url }} steps: - - name: Verify build output - run: ls -R apps/docs/.vitepress/dist + - name: List downloaded artifact contents + run: ls -R . - name: Deploy to GitHub Pages id: deployment From f9c05a5761063a96cf1760eb76abd68c581e6c92 Mon Sep 17 00:00:00 2001 From: Richie Permana Date: Sat, 22 Nov 2025 01:04:31 +0800 Subject: [PATCH 5/5] cicd: fix deployment issue --- .github/workflows/deploy-docs.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml index 94c53ef..c3db158 100644 --- a/.github/workflows/deploy-docs.yml +++ b/.github/workflows/deploy-docs.yml @@ -2,8 +2,7 @@ name: Deploy Docs on: push: - # branches: [main] - branches: [development] + branches: [main, development] permissions: contents: read @@ -47,9 +46,6 @@ jobs: run: pnpm build working-directory: apps/docs - - name: Verify build output - run: ls -R apps/docs/.vitepress/dist - - name: Upload artifact uses: actions/upload-pages-artifact@v3 with: @@ -64,9 +60,13 @@ jobs: url: ${{ steps.deployment.outputs.page_url }} steps: - - name: List downloaded artifact contents - run: ls -R . - - name: Deploy to GitHub Pages id: deployment uses: actions/deploy-pages@v4 + with: + # If on development branch, deploy as preview + preview: ${{ github.ref == 'refs/heads/development' }} + + - name: Show deployed URL + run: | + echo "Deployed URL: ${{ steps.deployment.outputs.page_url }}"