Trigger a Netlify build - #24
Open
NitzanSirota wants to merge 1 commit into
Open
Conversation
✅ Deploy Preview for base44-platform-starter ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
NitzanSirota
force-pushed
the
chore/trigger-netlify-build
branch
from
September 2, 2026 10:43
392d253 to
1df9984
Compare
NitzanSirota
added a commit
that referenced
this pull request
Sep 2, 2026
Netlify answers the deploy alias, deploy-preview-N--<site>.netlify.app, but hands the server handler the deploy permalink, <deploy-id>--<site>.netlify.app, in host and x-forwarded-host. Derived from the request, a preview named the permalink as the redirect proxy's forwarding target while the browser held the host-only state cookie on the alias, so every sign-in died as InvalidCheck: state value could not be parsed which is also what a missing cookie reports: parseCookie in @auth/core rewrites every cause into that one string. Netlify's own DEPLOY_PRIME_URL is the alias, so pin AUTH_URL to it. next.config.ts bakes the value into the build because the function's runtime environment does not carry Netlify's build variables. The pin applies only where no origin is set explicitly, leaving production, which sets NEXTAUTH_URL, and local dev, which sets neither, exactly as they were. Measured on the live deployments: /api/auth/providers on PR #24's alias reported the permalink as its own callback URL. Verified locally by building with DEPLOY_PRIME_URL=http://pinned-alias.example and requesting with a permalink Host: the decoded OAuth state carried the pinned origin, and redirect_uri stayed production's. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
NitzanSirota
added a commit
that referenced
this pull request
Sep 2, 2026
Netlify answers the deploy alias, deploy-preview-N--<site>.netlify.app, but hands the server handler the deploy permalink, <deploy-id>--<site>.netlify.app, in host and x-forwarded-host. Derived from the request, a preview named the permalink as the redirect proxy's forwarding target while the browser held the host-only state cookie on the alias, so every sign-in died as InvalidCheck: state value could not be parsed which is also what a missing cookie reports: parseCookie in @auth/core rewrites every cause into that one string. Netlify's own DEPLOY_PRIME_URL is the alias, so pin AUTH_URL to it. next.config.ts bakes the value into the build because the function's runtime environment does not carry Netlify's build variables. The pin applies only where no origin is set explicitly, leaving production, which sets NEXTAUTH_URL, and local dev, which sets neither, exactly as they were. Measured on the live deployments: /api/auth/providers on PR #24's alias reported the permalink as its own callback URL. Verified locally by building with DEPLOY_PRIME_URL=http://pinned-alias.example and requesting with a permalink Host: the decoded OAuth state carried the pinned origin, and redirect_uri stayed production's. Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Whitespace-only change to
docs/deploy.mdto trigger a Netlify deploy preview. No behavior change.🤖 Generated with Claude Code