Skip to content

fix: prevent infinite redirect loop when ROOT_PATH is set#950

Merged
tariqksoliman merged 6 commits intoNASA-AMMOS:developmentfrom
JPL-Devin:development
Apr 23, 2026
Merged

fix: prevent infinite redirect loop when ROOT_PATH is set#950
tariqksoliman merged 6 commits intoNASA-AMMOS:developmentfrom
JPL-Devin:development

Conversation

@tariqksoliman
Copy link
Copy Markdown
Member

With Devin

JPL-Devin#43

devin-ai-integration Bot and others added 6 commits April 23, 2026 18:43
Co-Authored-By: tariq.k.soliman <tariqksoliman@gmail.com>
…me-v2

fix: add curl to runtime stage for healthcheck support
When ROOT_PATH is set (e.g. /lunarsouthpole), Express non-strict route
matching causes app.get(ROOT_PATH) to match both /lunarsouthpole and
/lunarsouthpole/, creating an infinite 301 redirect loop.

Add a guard so the redirect only fires when the request path does NOT
already end with '/'. When it does, call next() to pass control to the
main application route handler.

Co-Authored-By: tariq.k.soliman <tariqksoliman@gmail.com>
…redirect-loop

fix: prevent infinite redirect loop when ROOT_PATH is set
@tariqksoliman tariqksoliman self-assigned this Apr 23, 2026
@tariqksoliman tariqksoliman added the bug Something isn't working label Apr 23, 2026
@tariqksoliman tariqksoliman merged commit 7745740 into NASA-AMMOS:development Apr 23, 2026
4 of 5 checks passed
@github-project-automation github-project-automation Bot moved this to Done in MMGIS Apr 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant