Hi gang,
Does anyone have any experience with nginx running mediawiki?
I've just migrated my sites from apache2 to nginx -- a WordPress site, a static site, and a mediawiki site are all running great from their own URLs.
The problem child is a mediawiki install I have in a subfolder of a WordPress installation. Trying to get to the mediawiki brings me right back to the root URL (the WordPress home page).
The directory structure is:
-wordpress site --subdirectory ---mediawiki install
Or, in other words:
wordpress.site/sub/mediawiki
Everything was running fine before the switch and I *suspect* I need to set something in an nginx.conf file... but... what?
Any help available will be REALLY appreciated.
Thanks!
Easy fix, Does nginx have something equivalent to apache's vhosts?
On Mon, Apr 21, 2014 at 8:37 AM, Matthew Wayne Selznick < mwselznick@gmail.com> wrote:
Hi gang,
Does anyone have any experience with nginx running mediawiki?
I've just migrated my sites from apache2 to nginx -- a WordPress site, a static site, and a mediawiki site are all running great from their own URLs.
The problem child is a mediawiki install I have in a subfolder of a WordPress installation. Trying to get to the mediawiki brings me right back to the root URL (the WordPress home page).
The directory structure is:
-wordpress site --subdirectory ---mediawiki install
Or, in other words:
wordpress.site/sub/mediawiki
Everything was running fine before the switch and I *suspect* I need to set something in an nginx.conf file... but... what?
Any help available will be REALLY appreciated.
Thanks!
-- Matthew Wayne Selznick Author, Creator and Creative Services Provider http://www.mattselznick.com Get a Free Sampler of My Short Stories, Novels, and Non-Fiction: http://www.mattselznick.com/free-ebook
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
It's likely something to do with your location rules. Instead of hitting the right wiki location a broad WordPress location is being hit.
First thing to do is share the nginx.conf you have related to WordPress and MediaWiki.
~Daniel Friesen (Dantman, Nadir-Seen-Fire) [http://danielfriesen.name/]
On 2014-04-20, 11:37 PM, Matthew Wayne Selznick wrote:
Hi gang,
Does anyone have any experience with nginx running mediawiki?
I've just migrated my sites from apache2 to nginx -- a WordPress site, a static site, and a mediawiki site are all running great from their own URLs.
The problem child is a mediawiki install I have in a subfolder of a WordPress installation. Trying to get to the mediawiki brings me right back to the root URL (the WordPress home page).
The directory structure is:
-wordpress site --subdirectory ---mediawiki install
Or, in other words:
wordpress.site/sub/mediawiki
Everything was running fine before the switch and I *suspect* I need to set something in an nginx.conf file... but... what?
Any help available will be REALLY appreciated.
Thanks!
Daniel would it be good if he was using rewrite on wordpress on apache to provide any rewrite rules?
On Mon, Apr 21, 2014 at 9:07 AM, Daniel Friesen daniel@nadir-seen-fire.comwrote:
It's likely something to do with your location rules. Instead of hitting the right wiki location a broad WordPress location is being hit.
First thing to do is share the nginx.conf you have related to WordPress and MediaWiki.
~Daniel Friesen (Dantman, Nadir-Seen-Fire) [http://danielfriesen.name/]
On 2014-04-20, 11:37 PM, Matthew Wayne Selznick wrote:
Hi gang,
Does anyone have any experience with nginx running mediawiki?
I've just migrated my sites from apache2 to nginx -- a WordPress site, a static site, and a mediawiki site are all running great from their own URLs.
The problem child is a mediawiki install I have in a subfolder of a WordPress installation. Trying to get to the mediawiki brings me right back to the root URL (the WordPress home page).
The directory structure is:
-wordpress site --subdirectory ---mediawiki install
Or, in other words:
wordpress.site/sub/mediawiki
Everything was running fine before the switch and I *suspect* I need to set something in an nginx.conf file... but... what?
Any help available will be REALLY appreciated.
Thanks!
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
Apache? He's running nginx now, Apache, its rewrites, and .htaccess files aren't relevant anymore.
~Daniel Friesen (Dantman, Nadir-Seen-Fire) [http://danielfriesen.name/]
On 2014-04-21, 12:11 AM, Jonathan Aquilina wrote:
Daniel would it be good if he was using rewrite on wordpress on apache to provide any rewrite rules?
On Mon, Apr 21, 2014 at 9:07 AM, Daniel Friesen daniel@nadir-seen-fire.comwrote:
It's likely something to do with your location rules. Instead of hitting the right wiki location a broad WordPress location is being hit.
First thing to do is share the nginx.conf you have related to WordPress and MediaWiki.
~Daniel Friesen (Dantman, Nadir-Seen-Fire) [http://danielfriesen.name/]
On 2014-04-20, 11:37 PM, Matthew Wayne Selznick wrote:
Hi gang,
Does anyone have any experience with nginx running mediawiki?
I've just migrated my sites from apache2 to nginx -- a WordPress site, a static site, and a mediawiki site are all running great from their own URLs.
The problem child is a mediawiki install I have in a subfolder of a WordPress installation. Trying to get to the mediawiki brings me right back to the root URL (the WordPress home page).
The directory structure is:
-wordpress site --subdirectory ---mediawiki install
Or, in other words:
wordpress.site/sub/mediawiki
Everything was running fine before the switch and I *suspect* I need to set something in an nginx.conf file... but... what?
Any help available will be REALLY appreciated.
Thanks!
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
On Mon, Apr 21, 2014 at 12:07 AM, Daniel Friesen daniel@nadir-seen-fire.com wrote:
It's likely something to do with your location rules. Instead of hitting the right wiki location a broad WordPress location is being hit.
First thing to do is share the nginx.conf you have related to WordPress and MediaWiki.
Here's that -- does it help?:
server { listen 80; root /var/www/mattselznick.com/public_html; index index.php index.html index.htm; server_name mattselznick.com www.mattselznick.com;
location / { try_files $uri $uri/ /index.php?q=$uri&$args; }
location ~ .php$ { try_files $uri =404; fastcgi_pass unix:/var/run/php5-fpm.sock; fastcgi_index index.php; include fastcgi_params; }
location /thehumanitycontinuum/wiki { try_files $uri $uri/ /index.php?q=$uri&$args; }
# For W3 Total Cache(W3TC) include /var/www/mattselznick.com/public_html/nginx.conf; # End W3 Total Cache(W3TC)
location ~* /(?:uploads|files)/.*.php$ { deny all; } }
Thanks!
On 2014-04-22, 3:36 PM, Matthew Wayne Selznick wrote:
On Mon, Apr 21, 2014 at 12:07 AM, Daniel Friesen daniel@nadir-seen-fire.com wrote:
It's likely something to do with your location rules. Instead of hitting the right wiki location a broad WordPress location is being hit.
First thing to do is share the nginx.conf you have related to WordPress and MediaWiki.
Here's that -- does it help?:
Yup, there are a number of problems with the config: - I don't recommend blacklisting php for uploads that way (that's not even protecting the wiki uploads anyways, is it?). A much nicer way is to enclose the .php handler such that when you define an empty location for the images dir the php handler simply doesn't exist under that path anymore. - The final entry for the try_files in your wiki section points to WordPress, not MediaWiki.
Proper nginx config for MediaWiki looks closer to this: http://shorturls.redwerks.org/?source=userdata&fcgi_params=%2Fetc%2Fngin...
What is the path to MediaWiki's index.php?
~Daniel Friesen (Dantman, Nadir-Seen-Fire) [http://danielfriesen.name/]
Hi Daniel,
On Tue, Apr 22, 2014 at 3:59 PM, Daniel Friesen daniel@nadir-seen-fire.com wrote:
- I don't recommend blacklisting php for uploads that way (that's not
even protecting the wiki uploads anyways, is it?). A much nicer way is to enclose the .php handler such that when you define an empty location for the images dir the php handler simply doesn't exist under that path anymore.
Makes sense. I'll have to learn a bit more before I understand quite how to act on that advice! Meanwhile, I'll comment it out.
- The final entry for the try_files in your wiki section points to
WordPress, not MediaWiki. Proper nginx config for MediaWiki looks closer to this: http://shorturls.redwerks.org/?source=userdata&fcgi_params=%2Fetc%2Fngin...
What is the path to MediaWiki's index.php?
http://www.mattselznick.com/thehumanitycontinuum/wiki/
This is very helpful, but I am still learning. Am I to understand that I would add the conf info from the above link in the wiki's location block?
After following Daniel's advice and muddling through the very useful shorturls.redwerks.org, I'm getting close... my previous short URLs don't work, though. For example, http://www.mattselznick.com/thehumanitycontinuum/wiki/Special:SpecialPages results in a 404. However, http://www.mattselznick.com/thehumanitycontinuum/wiki/index.php?title=Specia... DOES work.
Thoughts / guidance on getting me this last yard would be much appreciated...!
On Tue, Apr 22, 2014 at 4:25 PM, Matthew Wayne Selznick mwselznick@gmail.com wrote:
Hi Daniel,
On Tue, Apr 22, 2014 at 3:59 PM, Daniel Friesen daniel@nadir-seen-fire.com wrote:
- I don't recommend blacklisting php for uploads that way (that's not
even protecting the wiki uploads anyways, is it?). A much nicer way is to enclose the .php handler such that when you define an empty location for the images dir the php handler simply doesn't exist under that path anymore.
Makes sense. I'll have to learn a bit more before I understand quite how to act on that advice! Meanwhile, I'll comment it out.
- The final entry for the try_files in your wiki section points to
WordPress, not MediaWiki. Proper nginx config for MediaWiki looks closer to this: http://shorturls.redwerks.org/?source=userdata&fcgi_params=%2Fetc%2Fngin...
What is the path to MediaWiki's index.php?
http://www.mattselznick.com/thehumanitycontinuum/wiki/
This is very helpful, but I am still learning. Am I to understand that I would add the conf info from the above link in the wiki's location block?
-- Matthew Wayne Selznick Author, Creator and Creative Services Provider http://www.mattselznick.com Get a Free Sampler of My Short Stories, Novels, and Non-Fiction: http://www.mattselznick.com/free-ebook
Never mind! Daniel, THANK YOU. Further exploration of the redwerks.org site got me where I needed to be. It's working perfectly so far. Thanks again!
On Tue, Apr 22, 2014 at 5:27 PM, Matthew Wayne Selznick mwselznick@gmail.com wrote:
After following Daniel's advice and muddling through the very useful shorturls.redwerks.org, I'm getting close... my previous short URLs don't work, though. For example, http://www.mattselznick.com/thehumanitycontinuum/wiki/Special:SpecialPages results in a 404. However, http://www.mattselznick.com/thehumanitycontinuum/wiki/index.php?title=Specia... DOES work.
Thoughts / guidance on getting me this last yard would be much appreciated...!
On Tue, Apr 22, 2014 at 4:25 PM, Matthew Wayne Selznick mwselznick@gmail.com wrote:
Hi Daniel,
On Tue, Apr 22, 2014 at 3:59 PM, Daniel Friesen daniel@nadir-seen-fire.com wrote:
- I don't recommend blacklisting php for uploads that way (that's not
even protecting the wiki uploads anyways, is it?). A much nicer way is to enclose the .php handler such that when you define an empty location for the images dir the php handler simply doesn't exist under that path anymore.
Makes sense. I'll have to learn a bit more before I understand quite how to act on that advice! Meanwhile, I'll comment it out.
- The final entry for the try_files in your wiki section points to
WordPress, not MediaWiki. Proper nginx config for MediaWiki looks closer to this: http://shorturls.redwerks.org/?source=userdata&fcgi_params=%2Fetc%2Fngin...
What is the path to MediaWiki's index.php?
http://www.mattselznick.com/thehumanitycontinuum/wiki/
This is very helpful, but I am still learning. Am I to understand that I would add the conf info from the above link in the wiki's location block?
-- Matthew Wayne Selznick Author, Creator and Creative Services Provider http://www.mattselznick.com Get a Free Sampler of My Short Stories, Novels, and Non-Fiction: http://www.mattselznick.com/free-ebook
-- Matthew Wayne Selznick Author, Creator and Creative Services Provider http://www.mattselznick.com Get a Free Sampler of My Short Stories, Novels, and Non-Fiction: http://www.mattselznick.com/free-ebook
mediawiki-l@lists.wikimedia.org