Skip to content

Commit b3c378b

Browse files
committed
add Static Pages deployment
1 parent ca088c1 commit b3c378b

1 file changed

Lines changed: 25 additions & 8 deletions

File tree

.github/workflows/docs-website.yaml

Lines changed: 25 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ on:
1717

1818
jobs:
1919
build:
20-
if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.action != 'closed')
2120
runs-on: ubuntu-latest
2221
name: Build (Docs)
2322
steps:
@@ -27,8 +26,8 @@ jobs:
2726
- name: Setup Node.js
2827
uses: actions/setup-node@v4
2928
with:
30-
node-version: 'lts/*'
31-
cache: 'npm'
29+
node-version: "lts/*"
30+
cache: "npm"
3231
cache-dependency-path: docs/package-lock.json
3332

3433
- name: Install Dependencies
@@ -46,16 +45,12 @@ jobs:
4645
deploy-gh-pages:
4746
runs-on: ubuntu-latest
4847
needs: build
49-
if: github.event_name == 'push'
48+
if: github.event_name == 'workflow_dispatch' || github.event_name == 'push'
5049

5150
permissions:
5251
id-token: write
5352
pages: write
5453

55-
environment:
56-
name: github-pages
57-
url: https://calendarapi.specht-labs.de
58-
5954
steps:
6055
- name: Setup GitHub Pages
6156
uses: actions/configure-pages@v5
@@ -76,3 +71,25 @@ jobs:
7671
- name: Deploy to GitHub Pages
7772
id: deployment
7873
uses: actions/deploy-pages@v4
74+
75+
deploy-static-pages:
76+
runs-on: ubuntu-latest
77+
needs: build
78+
if: github.event_name == 'workflow_dispatch' || github.event_name == 'push'
79+
80+
permissions:
81+
id-token: write
82+
pages: write
83+
84+
steps:
85+
- name: Download Artifacts for Website
86+
uses: actions/download-artifact@v4
87+
with:
88+
name: site
89+
path: ./dist
90+
91+
- name: Upload to Static Pages
92+
uses: SpechtLabs/StaticPages-Upload@main
93+
with:
94+
endpoint: https://pages.specht-labs.de
95+
site-dir: dist/

0 commit comments

Comments
 (0)