A minimal private GitHub Pages demo repository for learning the Pages product end-to-end.
- GitHub Actions-based Pages deployment
- Static site artifact packaging and deployment
- Required Pages permissions (
pages: write,id-token: write) - Typical build and deploy job split
.github/workflows/pages.yml: Pages deployment workflowsite/index.html: Demo page contentsite/styles.css: Small styling file
- You can create private repositories in your org/account
- GitHub Pages is enabled for private repositories in your environment
- You have permissions to edit repository settings and Actions
- Create a new private repository in GitHub (for example:
pages-demo-private). - Copy this folder contents into that repository.
- Push to the
mainbranch. - In repository settings:
- Go to Pages
- Set Build and deployment source to GitHub Actions
- Open Actions and run the
Deploy private demo Pages siteworkflow (or push a commit). - After deploy succeeds, open the environment URL shown in the deploy job output.
Run these from this folder if gh is installed and authenticated:
git init
git add .
git commit -m "Initial private Pages demo"
git branch -M main
gh repo create pages-demo-private --private --source . --remote origin --push- Deployment permission errors:
- Check workflow has
pages: writeandid-token: write.
- Check workflow has
- No Pages URL after successful workflow:
- Confirm repository Pages source is set to GitHub Actions.
- 404 right after first deploy:
- Wait a minute for initial propagation and retry.
- Add a custom domain and test DNS flow
- Add a Jekyll workflow path (
actions/jekyll-build-pages) - Add preview deployment experiments (if enabled in your environment)