1

On mywebsite.com, I have running docker container with wordpress. I started it as

docker run -p 8000:80 --name docker-wordpress-nginx -d 

and

docker ps

shows

0.0.0.0:8000->80/tcp

and on my host I have nginx running with

server {
     listen   80;
...
server_name mywebsite.com www.mywebsite.com;
...
location / {
             proxy_pass http://localhost:8000/;
             proxy_set_header Host $host;
    }

I intentionally run docker container as 8000:80 becasue I have other things running on my host's port 80. I logged into

mywebsite.com:8000/wp-admin/

and

http://mywebsite.com:8000/wp-admin/options-general.php

and changed Site Address (URL) from

http://mywebsite.com:8000

to

http://mywebsite.com

So, now, after I go here:

http://mywebsite.com/wp-admin/

I am redirected here:

http://mywebsite.com:8000/wp-login.php?redirect_to=http%3A%2F%2Fmywebsite.com%2Fwp-admin%2F&reauth=1

and after I log in, I am show this page:

http://mywebsite.com/wp-admin/

and i see it correctly. However, if I click on any link inside, like "Pages" link, I got blank page

File not Found

as web page content and address bar shows:

http://mywebsite.com/wp-admin/edit.php?post_type=page

Also, I tried to login to admin interface as

http://mywebsite.com:8000/wp-admin/

And after i provide user/password, the Main admin page was shown, and after clicking on any link, like before, I got

File not found.

I tried using

define('WP_HOME','http://mywebsite.com');
define('WP_SITEURL','http://mywebsite.com');

in wp-config.php, but didn't help.

I really don't care whether I use

http://mywebsite.com:8000/wp-admin/

or

http://mywebsite.com/wp-admin/

as long as my admin interface works and I can use it without errors.

Any ideas?

1
  • Did you find any solution for this issue? Jan 16, 2017 at 10:29

0

You must log in to answer this question.

Browse other questions tagged .