# Redirecting to /ghost with admin subdomain

**URL:** <https://forum.ghost.org/t/redirecting-to-ghost-with-admin-subdomain/5418>\
**Category:** Developer help\
**Created:** [February 1, 2019, 7:09pm UTC](https://forum.ghost.org/t/redirecting-to-ghost-with-admin-subdomain/5418 "2019-02-01T19:09:21Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![safinn](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/safinn/32/2495_2.png) [@safinn](https://forum.ghost.org/u/safinn)\
**Post date:** [February 1, 2019, 7:09pm UTC](https://forum.ghost.org/t/redirecting-to-ghost-with-admin-subdomain/5418/1 "2019-02-01T19:09:21Z")

</div>

What do I need to change (nginx configs?) to always go to the admin page (/ghost) when going to my domain?

---

<div class="post-metadata">

**Author:** ![Hannah](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/hannah/32/22_2.png) [@Hannah](https://forum.ghost.org/u/Hannah)\
**Post date:** [February 1, 2019, 7:12pm UTC](https://forum.ghost.org/t/redirecting-to-ghost-with-admin-subdomain/5418/2 "2019-02-01T19:12:25Z")

</div>

The path for Ghost admin is always `/ghost/`.

> **[Configuration - Adapt your publication to suit your needs](https://ghost.org/docs/config/)**
>
> Find out how to configure your Ghost publication or override Ghost's default behaviour with robust config options, including mail, storage, scheduling and more!

There’s an open issue for it, PRs would be welcome 🙂

> <https://github.com/TryGhost/Ghost/issues/9872>
>
> I'm running \`ghost:2.1.2-alpine\` and I'm trying to host the \`/ghost\` panel under… a separate domain.
> I'm doing this because I have multiple ghost installations and I want one Google-based OAuth for all installations.
> 
> Now, I'm supplying an environment variable to the docker continer in the form of:
> \`\`\`
> admin\_\_url: "https://ghost.domain.mine/xyz/"
> \`\`\`
> But despite that the configuration is ignored, and when the API call to \`/ghost/api/v0.1/configuration/\` is made it is made for:
> \`\`\`
> https://ghost.domain.mine/ghost/api/v0.1/configuration/
> \`\`\`
> Which suggests to me that the \`xyz/\` sub-path of the \`admin\_\_url\` argument is ignored.
> Why is this?
> 
> My proxy config:
> \`\`\`nginx
> location /xyz {
> rewrite /xyz/(.\*) /ghost/$1 break;
> proxy\_pass http://127.0.0.1:8081/ghost;
> proxy\_redirect https://ghost.domain.mine/ghost/ /xyz/;
> proxy\_set\_header Host $host;
> proxy\_set\_header X-Forwarded-Proto $scheme;
> proxy\_set\_header X-Forwarded-For $proxy\_add\_x\_forwarded\_for;
> proxy\_set\_header X-Real-IP $remote\_addr;
> }
> \`\`\`

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex015/uploads/ghost2/original/2X/b/ba9ce5100b8bb264586f4f572545596b2ce3f081.png) [@system](https://forum.ghost.org/u/system)\
**Post date:** [February 15, 2019, 7:13pm UTC](https://forum.ghost.org/t/redirecting-to-ghost-with-admin-subdomain/5418/4 "2019-02-15T19:13:56Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
