Skip to content

Update from code changes: document HARLY_URL production validation - #33

Open
mintlify[bot] wants to merge 1 commit into
mainfrom
mintlify/6f4e9542
Open

Update from code changes: document HARLY_URL production validation#33
mintlify[bot] wants to merge 1 commit into
mainfrom
mintlify/6f4e9542

Conversation

@mintlify

@mintlify mintlify Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Summary

Document that Harly now validates HARLY_URL at startup in production and rejects HTTP, loopback, and bind addresses.

Changes

  • Added a HARLY_URL validation section to deployment/configuration.mdx covering the HTTPS requirement, rejected hostnames (localhost, 127.0.0.0/8, ::1, 0.0.0.0, ::), no-userinfo/query/fragment rule, and the startup-failure behavior.
  • Noted that every public URL (upload presign, file URLs, OAuth callbacks, redirects, metadata, webhooks, notifications, integrations) is derived from HARLY_URL, so reverse-proxy operators must not leak internal bind addresses.
  • Added a "Set HARLY_URL to the public hostname" subsection under the external reverse proxy guidance in self-hosting/proxy-modes.mdx, cross-linking to the validation reference.

Context

Follows #32, which hardened production configuration to reject internal origins in HARLY_URL.

Greptile Summary

This PR documents production validation and deployment guidance for configuring HARLY_URL.

  • Adds a validation reference covering HTTPS, public-hostname restrictions, URL components, and startup behavior.
  • Explains how HARLY_URL affects generated public URLs.
  • Adds reverse-proxy guidance and cross-links the relevant documentation pages.

Confidence Score: 4/5

The PR appears safe to merge, though the startup-validation documentation should distinguish the weaker configuration check from the later public-origin validation.

The documentation currently promises startup rejection of credentials, query strings, and fragments even though the startup configuration validator accepts them and the stricter rejection occurs only when the public-origin helper loads.

Files Needing Attention: apps/docs/deployment/configuration.mdx

Important Files Changed

Filename Overview
apps/docs/deployment/configuration.mdx Adds comprehensive HARLY_URL validation guidance, but overstates which URL components the startup configuration validator rejects.
apps/docs/self-hosting/proxy-modes.mdx Correctly directs reverse-proxy operators to configure the externally reachable HTTPS origin and links to the validation reference.

Fix All in Greploop

Fix All in Claude Code Fix All in Codex

Prompt To Fix All With AI
### Issue 1
apps/docs/deployment/configuration.mdx:26-27
**Startup rejection is overstated**

The startup configuration validator does not reject userinfo, query strings, or fragments as documented here; that stricter check occurs later in `getHarlyPublicOrigin()`, so an invalid value can pass startup configuration validation and fail only when an affected application path loads.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Reviews (1): Last reviewed commit: "docs: document HARLY_URL production vali..." | Re-trigger Greptile

Greptile also left 1 inline comment on this PR.

@mintlify

mintlify Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor Author

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
harly 🟢 Ready View Preview Aug 13, 2026, 1:10 PM

@readme-ai-writer

readme-ai-writer Bot commented Aug 13, 2026

Copy link
Copy Markdown

📚 No documentation changes were needed for this PR.

@strix-security

Copy link
Copy Markdown

Strix is installed on this repository, but we couldn't run this PR security review because this workspace's trial has ended. Add a card to resume code reviews here.

Comment on lines +26 to +27
- Contain no userinfo, query string, or fragment. Only scheme, host, and
optional port are accepted.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Startup rejection is overstated

The startup configuration validator does not reject userinfo, query strings, or fragments as documented here; that stricter check occurs later in getHarlyPublicOrigin(), so an invalid value can pass startup configuration validation and fail only when an affected application path loads.

Prompt To Fix With AI
This is a comment left during a code review.
Path: apps/docs/deployment/configuration.mdx
Line: 26-27

Comment:
**Startup rejection is overstated**

The startup configuration validator does not reject userinfo, query strings, or fragments as documented here; that stricter check occurs later in `getHarlyPublicOrigin()`, so an invalid value can pass startup configuration validation and fail only when an affected application path loads.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code Fix in Codex

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.

0 participants