Skip to content

Commit f74f6be

Browse files
Fix GitHub Pages deployment workflow
- Remove conflicting Actions-based Pages deployment - Add dashboard structure validation for PRs - Compatible with existing legacy Pages setup - Resolves workflow failures on PR checks
1 parent 151ac17 commit f74f6be

File tree

1 file changed

+33
-21
lines changed

1 file changed

+33
-21
lines changed

.github/workflows/main.yml

Lines changed: 33 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -11,31 +11,43 @@ on:
1111

1212
permissions:
1313
contents: read
14-
pages: write
15-
id-token: write
16-
17-
concurrency:
18-
group: "pages"
19-
cancel-in-progress: false
2014

2115
jobs:
22-
deploy:
23-
environment:
24-
name: github-pages
25-
url: ${{ steps.deployment.outputs.page_url }}
16+
validate:
2617
runs-on: ubuntu-latest
2718
steps:
2819
- name: Checkout
2920
uses: actions/checkout@v4
30-
31-
- name: Setup Pages
32-
uses: actions/configure-pages@v4
33-
34-
- name: Upload artifact
35-
uses: actions/upload-pages-artifact@v3
36-
with:
37-
path: './dashboard'
3821

39-
- name: Deploy to GitHub Pages
40-
id: deployment
41-
uses: actions/deploy-pages@v4
22+
- name: Validate dashboard structure
23+
run: |
24+
echo "Validating dashboard files..."
25+
26+
# Check if dashboard directory exists
27+
if [ ! -d "dashboard" ]; then
28+
echo "❌ Dashboard directory not found"
29+
exit 1
30+
fi
31+
32+
# Check if index.html exists
33+
if [ ! -f "dashboard/index.html" ]; then
34+
echo "❌ dashboard/index.html not found"
35+
exit 1
36+
fi
37+
38+
# Check if assets directory exists
39+
if [ ! -d "dashboard/assets" ]; then
40+
echo "❌ dashboard/assets directory not found"
41+
exit 1
42+
fi
43+
44+
echo "✅ Dashboard structure validation passed"
45+
echo "📁 Dashboard contents:"
46+
find dashboard -type f | head -10
47+
48+
- name: Deploy to main branch (main branch only)
49+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
50+
run: |
51+
echo "🚀 Deploying dashboard to GitHub Pages..."
52+
echo "Dashboard will be available at: http://nodeout.stormrelief.com/"
53+
echo "Note: Actual deployment happens via GitHub Pages legacy mode from main branch"

0 commit comments

Comments
 (0)