{"id":21835806,"url":"https://github.com/vtex/render-root-path-example","last_synced_at":"2025-03-21T14:25:23.092Z","repository":{"id":68365921,"uuid":"184935212","full_name":"vtex/render-root-path-example","owner":"vtex","description":"Reference app for root path feature implementation. This shows how a CDN should perform host and path rewriting.","archived":false,"fork":false,"pushed_at":"2020-12-02T12:53:15.000Z","size":28,"stargazers_count":1,"open_issues_count":0,"forks_count":2,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-01-26T10:08:15.368Z","etag":null,"topics":["xp-developer"],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vtex.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-05-04T19:16:18.000Z","updated_at":"2024-12-03T17:28:32.000Z","dependencies_parsed_at":"2023-04-25T12:01:14.810Z","dependency_job_id":null,"html_url":"https://github.com/vtex/render-root-path-example","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vtex%2Frender-root-path-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vtex%2Frender-root-path-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vtex%2Frender-root-path-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vtex%2Frender-root-path-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vtex","download_url":"https://codeload.github.com/vtex/render-root-path-example/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244812832,"owners_count":20514523,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["xp-developer"],"created_at":"2024-11-27T20:24:57.362Z","updated_at":"2025-03-21T14:25:23.063Z","avatar_url":"https://github.com/vtex.png","language":"TypeScript","readme":"# Render Root Path Feature Example\n\nReference app for root path feature implementation. This shows how a reverse proxy should perform host and path rewriting.\n\n## How root path support works in Render\n\nIf your main domain is served by a different platform or system and you want to scope a VTEX IO store in a fixed path prefix, you can use the Root Path feature.\n\nFor example, given a domain `mybrand.com`, if you want to serve your store under `mybrand.com/ar`, you must:\n\n1 - Create a public domain for your account and add it to License Manager, e.g. `mybrand.com.ar`.\n\n2 - For all requests to `mybrand.com/ar`, configure your reverse proxy to:\n\n  2.1 - Rewrite the `Host` header to `mybrand.com.ar`.\n\n  2.2 - Rewrite the request `path` removing the prefix. E.g. `/ar/my-product/p` becomes `/my-product/p`.\n  \n  2.3 - Add a `x-vtex-root-path` header to the request with the value of the removed prefix, e.g. `/ar`.\n\nThis will inform Render that all generated links in this site should be prefixed by the root path, in this case `/ar`.\n\n## Example proxy app\n\nThis is an example app that performs the rewrites and adds the header for test purposes.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvtex%2Frender-root-path-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvtex%2Frender-root-path-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvtex%2Frender-root-path-example/lists"}