Opened 8 months ago
Last modified 7 months ago
#60582 new feature request
Let WordPress multisite network setup be aware of Nginx Unit as a hosting environment
Reported by: | javorszky | Owned by: | |
---|---|---|---|
Milestone: | Future Release | Priority: | normal |
Severity: | normal | Version: | 6.5 |
Component: | Networks and Sites | Keywords: | needs-docs has-patch |
Focuses: | docs, administration, multisite | Cc: |
Description
Hi there,
I work at F5 on the NGINX Unit team. I'd like to get WordPress to recognise when it's running behind a Unit environment, much like Apache, IIS, and Nginx proper, looking at the server header is sufficient for this. I already have a proof of concept locally with the required code changes.
With that, I'd also like to help with adding configuration documentation to the handbook, and to help getting an official Unit-based docker container created as well.
There are a few prerequisites that we still need to take care of on our (NGINX Unit) side, however here are all the references for work we already have:
- PR to the WordPress docker library adding Unit: https://github.com/docker-library/wordpress/pull/875
- work to fix multisite handling within Unit: https://github.com/nginx/unit/issues/916
I'd like to start the conversation about adding a section to the handbook for Unit configurations like how NGINX has its own: https://developer.wordpress.org/advanced-administration/server/web-server/nginx/.
I'd like help validating that Unit can handle all instances of multisite and single site functionality in a way that is expected.
Let me know how else I can help. You can also find me in the WordPress Slack during normal working hours GMT.
Thanks,
Gabor
Change History (4)
#1
@
8 months ago
- Keywords needs-patch added
- Milestone changed from Awaiting Review to Future Release
#2
@
8 months ago
Created a PR in the github mirror per the docs on the ticket, which was auto-closed and not linked to here. It's https://github.com/WordPress/WordPress/pull/692, it has the code changes.
Updating the $is_nginx detection in wp-includes/vars.php sounds reasonable. I assume that's what your code change does?
I have to add a new global variable. NGINX and NGINX Unit are configured differently, which also means the existing NGINX page also can't be reused for Unit. This is also the reason we need to validate that multisite works correctly.
Thank you for the pointers to the docs and multisite channels, as well as the info about the docker images.
This ticket was mentioned in PR #6147 on WordPress/wordpress-develop by javorszky.
8 months ago
#3
- Keywords has-patch added; needs-patch removed
- Adds new global variable
$is_nginx_unit
- Checks server header for
Unit/
to determine whether the server environment is NGINX Unit - Links to a documentation page that does not exist yet
Trac ticket: Let WordPress multisite network setup be aware of Nginx Unit as a hosting environment
Updating the
$is_nginx
detection inwp-includes/vars.php
sounds reasonable. I assume that's what your code change does? If so, feel free to submit a PR against https://github.com/WordPress/wordpress-develop/ to reason about.Just for the record, that project is not maintained by the WordPress project, but by the Docker community.
For help with Multisite testing, #core-multisite on Slack would be a good starting point.
Once things are working, #docs is a good starting point for documentation. See also https://make.wordpress.org/docs/handbook/.