Official Documentation On Wordpress Config
Hi Guys,
I have found tons on the internet around Nginx and Wordpress but nothing on Nginx Proxy Manager and Wordpress. Have been troubleshooting my install for a few weeks with no success.
Would it be possible for the official documentation on how to route WordPress sites?
Very least it will help with preventing bug reports for those who don't realize all the things they need to do.
Thanks!
Did you find a solution? I was stuck on this for two days, but I finally figured it out. Maybe I can help you.
I agree to @Fatman2142 and would love to see such an official documentation on 'docker, wordpress and with nginx-proxy-manager'
The same in https://github.com/NginxProxyManager/nginx-proxy-manager/issues/400 A lot of hints, examples, but most of them about 1-4 years old. Nothing worked for me... I'm getting '502 Bad Gateway', WP over http:// is running fine.
I tried to set up nginx-proxy-manager for my WordPress site but the web page is responding a 502 bad gateway error.
Here are some Screenshot.
I just can't make it work. Can anyone help me please ?
I tried different things
and different ssl settings
@RemyDG0 do you still have the problem ?
@remylavergne Yes, I still do have this issue. My problem is I don't really know where to look, all tutorials I saw only talked about command lines or files edit, it is just like if the web gui does not exists. Then I am not really sure how to access those.
I can maybe help you if you have same "config" as mine :
- using a VPS
- nginx proxy manager deployed with docker
- wordpress deployed with docker
Let me know.
@remylavergne Did you mean a VPN instead of VPS ? I don't use either. I use both packages as docker images but the docker host is TrueNas scale and they customised it a little. Does the configuration need to be done outside of of the Web user interface ?
I don't have expertise with TrueNAS sorry :/
I don't have expertise with TrueNAS sorry :/
I found how to access the console, the docker image and web gui are the same, my question if settings for setting up Wordpress are only available in the console
My NPM config :
The hostname / ip should point to the Wordpress container.
In Wordpress you should add the domain in configuration :
Don't forget to add your wordpress container in the same network as NPM (my biggest mistake) :
networks:
proxy_manager_default:
external: true
The docker ps output :
I assume that your TrueNAS runs inside a private network, so don't forget to open internet box ports, and your domain should CNAME / A RECORD to your server IP :
Thank you so much for your config @remylavergne, I now understand what was not working for me ! It now works !! My mistake was basically to select https instead of http for the scheme in the Edit Proxy Host window. It mislead me making me think that it was necessary in order to use ssl.
@RemyDG0 Perfect 😎
I have had a working wordpress install
it no longer works correctly behined NPM
I am getting this error:
Bad Request
Your browser sent a request that this server could not understand.
Apache/2.4.62 (Debian) Server at 10.0.16.18 Port 80
Initially i thought this was a corruption issue with my wordpress install, however i have hit exactly the same issue with a brandnew install
I have used the following custom location settings for /
proxy_set_header Host $host:$server_port;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
i have nothing set in the advanced tab of the server defintion
its not cookies - this happens in a fresh incognito window
any ideas?
for my fresh install with the same issue this is the compose
services:
wordpress:
image: wordpress
ports:
- 8180:80
deploy:
mode: replicated
replicas: 1
restart_policy:
condition: on-failure
delay: 5s
max_attempts: 3
window: 120s
environment:
WORDPRESS_DB_HOST: db:3306
WORDPRESS_DB_USER: redacted
WORDPRESS_DB_PASSWORD: redacted
WORDPRESS_DB_NAME: wordpressdb
WORDPRESS_HOSTNAME: mydomain.com
WORDPRESS_CONFIG_EXTRA: |
/* Multisite */
define('WP_ALLOW_MULTISITE', true );
define('MULTISITE', true);
define('SUBDOMAIN_INSTALL', true);
define('DOMAIN_CURRENT_SITE', 'mydomain.com');
define('PATH_CURRENT_SITE', '/');
define('SITE_ID_CURRENT_SITE', 1);
define('BLOG_ID_CURRENT_SITE', 1);
/* Alternate CRON for backup plugin */
define( 'ALTERNATE_WP_CRON', true );
volumes:
- html:/var/www/html
extra_hosts:
- mydomain.com:my-external-ip
db:
image: mysql:8.0
environment:
MYSQL_ROOT_PASSWORD: redacted
MYSQL_DATABASE: wordpressdb
MYSQL_USER: redacted
MYSQL_PASSWORD: redacted
deploy:
mode: replicated
replicas: 1
restart_policy:
condition: on-failure
delay: 5s
max_attempts: 3
window: 120s
volumes:
- db:/var/lib/mysql
volumes:
html:
driver: local
driver_opts:
type: none
device: "/mnt/docker-cephFS/wordpress_html"
o: bind
db:
driver: local
driver_opts:
type: none
device: "/mnt/docker-cephFS/wordpress_db"
o: bind
Issue is now considered stale. If you want to keep it open, please comment :+1: