Skip to content

FRONTEND_URL defaults to http://localhost:3001, but the Next.js frontend serves on :3000 — CORS and the OAuth redirect miss it #590

Closed

Description

@chonilius

Problem

configuration.ts and .env.example default FRONTEND_URL to http://localhost:3001. It's used both as the only CORS origin (enableCors({ origin })) and as the OAuth redirect target. next dev (MergeFi/frontend) runs on 3000, which is also this backend's own default PORT. A local setup that follows both READMEs gets CORS failures on every API call and an OAuth redirect to a port nothing listens on.

Suggested fix

Default the backend to PORT=4000 (which the frontend's NEXT_PUBLIC_API_URL already assumes) and FRONTEND_URL=http://localhost:3000, and update .env.example and the README.

Activity

  1. tresjo81 commented on Oct 13, 2026

    @tresjo81

    Hi maintainers! I would like to take this on. I've checked the configuration setup: I will default PORT to 4000 and FRONTEND_URL to http://localhost:3000 in configuration.ts, update .env.example, and adjust the README so local setups align with Next.js out of the box. Ready to start and submit a clean PR right away upon assignment.

  2. AminMG044 commented on Oct 19, 2026

    @AminMG044

    @AminMG044 has applied to work on this issue as part of the Stellar Wave Program's 10th wave.

    Hello Maintainer, I reviewed the current implementation and understand the changes required to meet the issue's expectations. I'll approach it with maintainability and compatibility in mind.

    ℹ️ Repo Maintainers: To accept this application, review their application or assign @AminMG044 to this issue.

  3. yodakkak commented on Oct 19, 2026

    @yodakkak

    @yodakkak has applied to work on this issue as part of the Stellar Wave Program's 10th wave.

    Hello! I'd love to work on this issue and align the default FRONTEND_URL config and tests. Ready to submit a clean PR right away — kindly assign me.

    ℹ️ Repo Maintainers: To accept this application, review their application or assign @yodakkak to this issue.

  4. devpeter999 commented on Oct 19, 2026

    @devpeter999
    Contributor

    @devpeter999 has applied to work on this issue as part of the Stellar Wave Program's 10th wave.

    Hi maintainer! I’d like to work on this issue. I’ve reviewed the requirements and would be happy to take it up. Please assign it to me.

    ℹ️ Repo Maintainers: To accept this application, review their application or assign @devpeter999 to this issue.

  5. drips-wave commented on Oct 19, 2026

    @drips-wave

    Congratulations, @devpeter999! 🎉 Your application was accepted by the repo's maintainers, and the issue is due on October 22, 2026.

    🧑‍💻 @devpeter999: Please resolve the issue such that the repo's maintainers have enough time to review your contribution before the due date. You'll earn Points for completing the issue on-time, which will make you eligible for a share of the Stellar Wave Program's reward pool.

    Warning

    When opening a PR, please link it to this issue to ensure it gets tracked accurately. Points are awarded when this issue is marked as completed by the maintainer.

    🤠 Repo maintainers: Please keep an eye on the contributor's progress and review their work before the due date. You can manage this issue, including adjusting its complexity and points, here.

    🌊 Happy Wave 🌊

  6. grantfox-oss commented on Oct 20, 2026

    @grantfox-oss

    🎉 This issue has been marked as completed on GrantFox!

    @devpeter999's PR #709 was approved and merged by @chonilius.

    🏆 @devpeter999: You earned 35 FoxPoints for this contribution! Your current tier: Explorer (411 total points). Track your full progress on GrantFox.

    👏 Great work, @devpeter999! Keep contributing to MergeFi.

  7. drips-wave commented on Oct 20, 2026

    @drips-wave

    This issue has been completed by @devpeter999 as part of the Stellar Wave Program's 10th Wave 🥳

    😎 @devpeter999: You earned 200 Points for completing this issue! Once the Wave's rewards are finalized, you'll be eligible for a percentage of the Wave's reward pool based on the percentage of total points you've earned. Learn more here. You can also Leave a review to share your experience working on this issue.

    🧑‍💻 Repo maintainers: How'd the contributor do? Leave a review to share your experience working with them.

  8. added a commit that references this issue on Oct 20, 2026
    e5f8c0c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programbugSomething isn't workinggood first issueGood for newcomers

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions