Switch staging → prod (publish site to final customdomain)
Once staging looks good on the default GitHub Pages URL, we “ship to production” by attaching the final domain.
Before you start: DNS + registrar
Do DNS first, then set the custom domain in GitHub Pages.
See: DNS
Publish the site on the custom domain (GitHub Pages)
1) GitHub repo → Settings → Pages
2) Under Custom domain, enter the final domain (e.g. example.com or example.com.uy) and save.
3) Wait for DNS checks to pass (GitHub will show status).
Enforce HTTPS (important)
After the site is published on the custom domain:
1) GitHub repo → Settings → Pages
2) Enable Enforce HTTPS
3) Wait ~10 minutes, then refresh.
Sometimes you need to toggle/refresh and let it settle twice before it sticks.
Set prod URL on astro.config.mjs
Once the site is live on the final domain, update astro.config.mjs so Astro generates correct absolute URLs for production.
Typical production config (replace your-domain.uy):
import { defineConfig } from "astro/config";
export default defineConfig({
site: "https://your-domain.uy",
base: "",
});
Also search the repo for any other BASE_URL-like constants (or hardcoded staging URLs) and update them to match production.