Skip to content

ci: deploy docs previews to the preview target only - #32126

Draft
nickvigilante wants to merge 1 commit into
mainfrom
vigilante/docs-preview-target
Draft

nickvigilante wants to merge 1 commit into
mainfrom
vigilante/docs-preview-target

Conversation

@nickvigilante

Copy link
Copy Markdown
Collaborator

Docs PR previews (#30698) could become the preview project's production deployment. Vercel makes a project's first deployment production, and closing #32098 had just deleted the last deployments in coder-docs-pr-preview, so the next deploy, for #31992, was assigned to production and aliased at coder-docs-pr-preview-prod.docs.cdr-preview.dev. The CLI said so: "This is your project's first deployment, so it was assigned to production." #31992's own pr-31992 aliases were set as usual.

This passes --target=preview to vercel deploy, so a PR preview is never production regardless of what's in the project. test-docs-preview-mapper.sh gains a check that the single deploy command carries --target=preview and that nothing in the workflow deploys with --prod or --target=production; it fails against main's workflow and passes with this change.

The existing production deployment (dpl_Di1vwonwpGZbfvveixmRRQgRYezP, serving #31992's content) carries no pr tag, so the cleanup workflow won't find it. It should be deleted by hand in the coder-docs-pr-preview project once #31992 closes; deleting it sooner would take #31992's preview down with it.

Testing

All mapper tests pass with GNU coreutils, sed, grep and awk on macOS, including the new one; it fails against main's workflow. actionlint and ShellCheck report nothing.


🤖 Built with AI assistance.

Vercel makes a project's first deployment production. When closing a PR
deleted the last deployments in the preview project, the next PR's deploy
became that project's production deployment, aliased at
coder-docs-pr-preview-prod. The deploy now passes --target=preview, so a
PR preview is never promoted, and a test fails if the deploy loses the
flag or anything deploys to production.

Assisted-by: AI
@nickvigilante
nickvigilante temporarily deployed to main November 12, 2026 19:54 — with GitHub Actions Inactive
@nickvigilante
nickvigilante temporarily deployed to main November 12, 2026 19:54 — with GitHub Actions Inactive
@linear-code

linear-code Bot commented Nov 13, 2026

Copy link
Copy Markdown

DOCS-1747

This branch was previously deployed

1 inactive deployment
main — d25c11a2 Deployed Nov 12, 2026 by nickvigilante via cla #255254
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant