Skip to content

Packs / github-ops-public

github-pages

Publish a static site on GitHub Pages (branch or Actions build), check it, and know when to use Cloudflare Pages instead (git-connected previews, custom domains on our Cloudflare zones).

Install

logicpacks pack use github-ops-public/github-pages
get_pack github-ops-public/github-pages

The second line is the MCP tool call for the LogicPacks connector (Claude Code, Codex, Claude.ai and others). The first run of a pack someone else wrote asks for your yes.

Keys it needs (names only)

  • GITHUB_TOKEN

Playbooks included

  • Spec: spec/SPEC.md (goal, steps, edge cases, don’ts)
  • Routes: gh-cli
  • Checks: 2 in outcome/checks.yaml
  • Code: enable_pages.sh
  • Tools: gh, curl

Usage, last 8 weeks

New: no recorded use yet.

Purpose (from spec/SPEC.md)

Publish a static site on GitHub Pages (branch or Actions build), check it, and know when to use Cloudflare Pages instead (git-connected previews, custom domains on our Cloudflare zones).

Goal

A static demo or docs site live at .github.io/ (or a custom domain) with one command.

Steps

  1. Make sure the repo is public (Pages on private repos needs a paid plan) and Waleed approved making it public.
  2. Enable from a branch: gh api -X POST repos/<o>/<r>/pages -f 'source[branch]=main' -f 'source[path]=/' (or build_type=workflow with actions/deploy-pages).
  3. Wait for the build: gh api repos/<o>/<r>/pages/builds/latest --jq .status until built.
  4. Check: curl -fsS -o /dev/null -w '%{http_code}' https://<user>.github.io/<repo>/ = 200, and open it at 390px.
  5. For sites on our domains with preview builds per branch, prefer Cloudflare Pages git-connected (see the cloudflare space).

Edge cases

  • Asset paths must be relative or include the // base path.
  • No server code: static files only.

Don'ts

  • Don't publish private client work on Pages.