scope deploy static dist

This commit is contained in:
Alexa Amundson
2025-11-16 02:10:38 -06:00
parent a32601cf72
commit 734a04b35f
2 changed files with 20 additions and 7 deletions

View File

@@ -24,13 +24,23 @@ jobs:
- name: Checkout - name: Checkout
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Prepare static dist
# Only publish the static front-end assets (backend/static + root HTML) to Pages/GoDaddy
run: |
rm -rf dist
mkdir -p dist
cp -R backend/static/. dist/
if [ -f index.html ]; then
cp index.html dist/
fi
- name: Setup Pages - name: Setup Pages
uses: actions/configure-pages@v4 uses: actions/configure-pages@v4
- name: Upload artifact - name: Upload artifact
uses: actions/upload-pages-artifact@v3 uses: actions/upload-pages-artifact@v3
with: with:
path: '.' path: './dist'
- name: Deploy to GitHub Pages - name: Deploy to GitHub Pages
id: deployment id: deployment

View File

@@ -52,14 +52,17 @@ cd BlackRoad-Operating-System
open index.html open index.html
``` ```
### GitHub Pages Deployment ### GitHub Pages / GoDaddy Deployment
This project can be easily deployed to GitHub Pages: Only the static UI should be served from GitHub Pages or GoDaddy. The backend API and services continue to run on Railway so they remain isolated from the static hosting tier.
1. Go to your repository settings The default `Deploy to GitHub Pages` workflow now bundles the canonical front-end (everything under `backend/static` plus root-level assets such as `index.html`) into a temporary `dist/` directory before uploading it. This ensures that Pages/GoDaddy only receives the static bundle, while the backend code stays out of the artifact and continues to deploy independently to Railway.
2. Navigate to "Pages" section
3. Select the branch you want to deploy To publish manually without the workflow:
4. Your site will be available at `https://[username].github.io/BlackRoad-Operating-System/`
1. Copy the contents of `backend/static/` and any required root assets into a temporary folder (e.g., `dist/`).
2. Upload that folder to your Pages or GoDaddy hosting destination.
3. Keep the backend running on Railway so the static UI can communicate with the live services.
## Architecture ## Architecture