Ghost in a subpath with apache2 redirect failed


#1

I’m using Apache2 and set my config file as follow to redirect any access from http://myhost.top/ghost to localhost:2368 where ghost serving on this port.

        ProxyPass /ghost http://127.0.0.1:2368/
        ProxyPassReverse /ghost http://127.0.0.1:2368/

And I set the ghost config:

   "url":"http://myhost.top/ghost"`

But I get cannot GET / as the response (when I open “myhost.top/ghost”)

If I use the ghost config:

    "url":"http://myhost.top/"

now I can get a frontpage without css and js file loaded. Which config should I use?


#2

Should I install the ghost under /var/www/ghost/ ?


#3

I’ve made it.
Use the Apache config

        ProxyPass /gblog http://127.0.0.1:2368/gblog
        ProxyPassReverse /gblog http://127.0.0.1:2368/gblog

and the ghost config

url:http://example.top/gblog

In case somebody run into the same problem, ghost CANNOT use /ghost as the subpath


closed #4

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