Re: rewriting $arg into request.

2020-01-31 Thread Steve Wilson
On 31/01/2020 12:37, Reinis Rozitis wrote: if ($arg_p) { return 301http://yoursite/p/$arg_p; } This is what I was originally looking for, however as I've only 20 pages to manage the individual redirects via the map directive I believe will work better as it will remove a additional r

Re: rewriting $arg into request.

2020-01-31 Thread Steve Wilson
2020 11:28, Francis Daly wrote: On Fri, Jan 31, 2020 at 01:13:30AM +, Steve Wilson wrote: Hi there, Currently wordpress is using ugly urls for posts, so "/?p=1234" in wordpress might be "/this_nice_title" in hugo. Now hugo allows me to specify aliases too which I'd

rewriting $arg into request.

2020-01-30 Thread Steve Wilson
I'm currently in the process of transitioning from wordpress to hugo. For anyone not familiar with these, wordpress is php based and hugo outputs static content (keeping it simple) Currently wordpress is using ugly urls for posts, so "/?p=1234" in wordpress might be "/this_nice_title" in hugo. N

Re: Resolver not working as expected

2018-08-28 Thread Steve Wilson
On 27/08/2018 14:30, Maxim Dounin wrote: Hello! On Mon, Aug 27, 2018 at 06:56:01PM +0530, Sharan J wrote: Hi, Sample conf: http{ resolver x.x.x.x; server { server_name _; location / { proxy_pass http://somedomain.com; } } I have nameservers configured in my r

Re: dual stack binding

2018-06-21 Thread Steve Wilson
I've no problem with IPv6 on my server using specific v4 and v6 listen statements. Is the IP you're trying to use actually configured on an interface? Steve. On 21/06/2018 21:37, abatie wrote: I have nginx binding to a variety of addresses for ssl and target selection reasons. Now I'm trying

Re: Last roadblock changing from Apache: SSL & PHP

2017-05-14 Thread Steve Wilson
Hi, It doesn't look like that's actually getting passed to php-fpm. You're possibly missing the php handling in your server{} block. Check that you've got a location set for php files to do a fastcgi_pass. eg. location ~ \.php$ { fastcgi_pass unix:/var/run/php-fpm/sock;

Re: How to encrypt proxy cache

2017-04-03 Thread Steve Wilson
On 03/04/2017 16:50, sachin.she...@gmail.com wrote: Thanks Maxim for the reply. We have evaluated disk based encryption etc, but that does not prevent sysadmins from viewing user data which is a problem for us. Do you think we could build something using lua and intercept read and wriite call

Re: NGINX http-secure-link iphone issue !!

2016-08-10 Thread Steve Wilson
My initial thoughts here are that you're potentially putting private information in the public hands. iirc to use http_secure_link you need some "private" information to generate the md5sum. This data should not be part of a mobile application. Personally I'd look at a way to get the full url from

Re: Redirection 301 create "Redirection loop" while using wordpress site.

2016-04-12 Thread Steve Wilson
It sounds to me like wordpress believes that www is required and nginx doesn't want it. I'd try commenting out the redirect server{} block and add the server_name to the xxx.com one and see what you end up with in your browser, then have a look through the wordpress settings to see what it's want

Re: Http2 not getting enable

2015-10-03 Thread Steve Wilson
>From the limited testing I did when I enabled http2 on my sites, I found that the few sites I used for testing were actually checking for spdy and not http2/h2 as the next protocol. I've had the spdy indicator plugin in chrome for a while which I believe uses the chrome internals to check protoco

Re: reverse proxy + basic authentication

2015-09-16 Thread Steve Wilson
Adding the below should remove any authentication headers in the request to the backend server(s). proxy_set_header "Authorization" ""; Steve. On 15/09/2015 14:33, derp14 wrote: Hello, Please excuse me if this has been asked/solved before. I've searched an answer for some good hours but have

Re: nginx IETF RFC21266 Compliance - 'Proxy-Connection'

2015-09-16 Thread Steve Wilson
At risk of repeating previous advice, see below ... Original Message Subject: Re: nginx RFC21266 Compliance - 'Proxy-Connection' Date: 25/08/2015 21:21 From: Steve Wilson To: nginx@nginx.org Reply-To: nginx@nginx.org Looking at https://en.wikipedi

Re: Update on: nginx makes mysqld die all the time

2015-08-25 Thread Steve Wilson
Hi, On 25/08/2015 08:36, M. Fioretti wrote: > On 2015-08-18 15:23, M. Fioretti wrote: >> Greetings, >> >> I just migrated to nginx + php-fpm from apache a few websites, on a >> centos 6.6 virtual server. The sites are up but... now mysqld >> (MariaDB, actually) dies every 10/20 **minutes** with st

Re: nginx RFC21266 Compliance - 'Proxy-Connection'

2015-08-25 Thread Steve Wilson
Looking at https://en.wikipedia.org/wiki/List_of_HTTP_header_fields it suggests it's a non-standard request header. You can probably strip this out of the request to the real server with proxy_set_header "Proxy-Connection" ""; Although I'd expect the backend server to ignore invalid request head

Re: nginx makes mysqld die all the time

2015-08-19 Thread Steve Wilson
19/08/2015 07:02, M. Fioretti wrote: On 2015-08-18 14:36, Steve Wilson wrote: Hi, When I migrated from apache+mod_php to nginx+php-fpm I found I had a few websites using persistent mysql connections which never closed. Steve, thanks for this tip. This surely was part of the problem, but not all o

Re: nginx makes mysqld die all the time

2015-08-18 Thread Steve Wilson
Hi, When I migrated from apache+mod_php to nginx+php-fpm I found I had a few websites using persistent mysql connections which never closed. I had to disable this in the php.ini so all the sites fell back to using non-persistent connections. I don't know if this will help as it was mysql not m

Re: Nginx with Mailman

2015-03-26 Thread Steve Wilson
There seems to be a naming issue for the socket. nginx is configured to use /run/lists.sock yet your ls shows lists.sock-1 Steve. On 26/03/2015 13:15, Silvio Siefke wrote: > Hello, > > i try to run mailman on nginx over fcgiwrap. The sock is present on > system and has correct rights, but > log

Re: Will this work, is it the best way?

2015-01-31 Thread Steve Wilson
…] > considering your primary intent for server2 is IPv6 usage > > • Perhaps you meant upstream localhost:[…] to try both IPv4 and IPv6? > Thanks > > Cheers, > Lloyd > > On Friday, January 30, 2015, Steve Wilson <mailto:lists-ng...@swsystem.co.uk>> wrote: > >

Will this work, is it the best way?

2015-01-30 Thread Steve Wilson
Hi, Slightly complicated setup with 2 nginx servers. server1 has a public ipv4 address using proxy_pass to server2 over ipv6 which only has a public ipv6, this then has various upstreams for each subdomain. ipv6 capable browsers connect directly to server2, those with only ipv4 will connect

Re: Problem with wildcard of domain in nginx and in https

2015-01-14 Thread Steve Wilson
On 14/01/2015 10:30, ramsoft75 wrote: Isn't this ? server { listen 443 ssl spdy; server_name domain.com; ... } With that configuration if a go https://domains.com it gives me a error "webpage not avaiable" I'm guessing the above is a typo in the mail and that you're not actually trying

Re: SPDY for http?

2014-12-19 Thread Steve Wilson
On 18/12/2014 13:02, Lukas Tribus wrote: >> Hello all, >> >> I have a nginx site configured with spdy on https. >> >> But after reading >> https://developers.google.com/speed/articles/spdy-for-mobile I decided >> to try spdy also for http. >> >> But strangely, after reloading the page on http, the

Re: serve content from a wget mirror

2014-11-25 Thread Steve Wilson
On 24/11/2014 12:36, Francis Daly wrote: > On Mon, Nov 24, 2014 at 11:05:10AM +0000, Steve Wilson wrote: > > Hi there, > >> I'm trying to create an archive based on a current site which is due to >> be taken down, I've used "wget -m" to mirror the

serve content from a wget mirror

2014-11-24 Thread Steve Wilson
Hi, I'm trying to create an archive based on a current site which is due to be taken down, I've used "wget -m" to mirror the site and all seems well except I'm having trouble with what I think are arguments in the url. Most everything seems to work ok and this is currently my only issue. I have o

Re: Deny certain words

2014-09-03 Thread Steve Wilson
I've just thought of another angle for this. Is this hitting your default/only site? If it's got a host header you could create a site just for that that bins all requests off with a 444 and no logging. On 02/09/2014 12:08, Grozdan wrote: Hi, Somehow my server gets hit by torrent requests whi

Re: Deny certain words

2014-09-03 Thread Steve Wilson
On 02/09/2014 17:38, Grozdan wrote: On Tue, Sep 2, 2014 at 3:09 PM, Maxim Dounin wrote: Hello! On Tue, Sep 02, 2014 at 12:17:12PM +0100, Steve Wilson wrote: Torrent clients have their own user agent normally, I had a need a while back to block some which we used the magic 444 to kill it

Re: Deny certain words

2014-09-02 Thread Steve Wilson
Torrent clients have their own user agent normally, I had a need a while back to block some which we used the magic 444 to kill it. if ($http_user_agent ~* (uTorrent|Transmission) ) { return 444; break; } On 02/09/2014 12:08, Grozdan wrote: Hi, Somehow my server gets hit by torrent requests

Re: RE: GeoIP FirstNonPrivateXForwardedForIP

2014-06-23 Thread Steve Wilson
On 23/06/2014 12:05, Keyur wrote: Thanks Jonathan! Well I can not comment regarding getting professional service. Infact I will be glad to have support but If I go with this approach then I would rather be asked to use web server which supports the said feature. (This is doable in apache). A

Re: using 2000+ ip prefixes in nginx geo module !!

2014-06-19 Thread Steve Wilson
These 2 overlap 110.93.192.0/24 TW; 110.93.192.0/18 TW; The /24 is within the /18. In this instance you want to remove the /24. It might be worth investigating if you've got any others that overlap. I think you can probably override with a differ

Re: Nginx on Windows PHP fastcgi read timeouts

2014-06-17 Thread Steve Wilson
On 18/06/2014 00:39, c0nw0nk wrote: > I am still having the same issue read time outs. If every request made to > the server circles the upstream then it has to be the upstream that is the > issue not php. PHP loads are fine no crashes no errors. What's in the logs? Steve. _

Re: Nginx on Windows PHP fastcgi read timeouts

2014-06-17 Thread Steve Wilson
I'm not sure how you'd diagnose this on windows, I had a similar issue with php-fpm under linux as it was running out of "handlers". Could it be that all 20 of your fastcgi processes are in use and nginx is waiting for one to become available? As a side note, why windows? I'm curious why you'd be

Re: How could I forbid outside visits without response 403

2014-06-13 Thread Steve Wilson
On 13/06/14 15:14, 姚锟 wrote: > Hi Buddy, > I am a newer to Nginx world, now I have a project to link the varnish > HTTP server and nginx together, nginx is the back end. > > I want to allow the connections only by varnish, so I use deny all > ,this kind of stuff to archieve this. > > But if there

Re: NGINX: Reverse Proxy (SSL) with non-ssl backend

2014-05-28 Thread Steve Wilson
It's late and I'm about to go to bed so I've not checked the docs on this but ... add_header Front-End-Https on; I suspect this is meant to be proxy_add_header and meant so php can detect the client is accessing via https. If my memory is correct on this it's likely that php co

Re: how to configure nginx with running apache ?

2014-04-17 Thread Steve Wilson
I've had a situation whereby a legacy django install was running on apache, nginx was used for caching static content on this and to serve other locations. I have another server that started off infront of apache and one by one over several weeks vhosts were migrated to nginx with the default

Re: Strange nginx issue

2014-04-07 Thread Steve Wilson
On 07/04/2014 16:45, Steve Wilson wrote: > A quick read at > http://dev.mysql.com/doc/refman/4.1/en/innodb-parameters.html#sysvar_innodb_flush_log_at_trx_commit > suggests there's a possibility of losing 1s worth of data. I'm not sure > if we'd still have a problem wit

Re: Strange nginx issue

2014-04-07 Thread Steve Wilson
such issues. For > optimization we done the above changes and causing this issue. > > So can you please help me. > > On Mon, Apr 7, 2014 at 8:33 PM, Steve Wilson > wrote: > > I've just done a drupal7 site under nginx+php-fpm on debian. > > One thing I noti

Re: Strange nginx issue

2014-04-07 Thread Steve Wilson
I've just done a drupal7 site under nginx+php-fpm on debian. One thing I noticed was that the php process wasn't closing fast enough, this was tracked down to an issue with mysql. Connections were sitting idle for a long time which basically exhausted the fpm workers on both the web servers.

Re: SSL OCSP stapling won't enable

2013-12-14 Thread Steve Wilson
I'm using startssl for my certificates so had problems with the ssl_trusted_certificate too. just using resolver and ssl_stapling on got mine enabled. Using openssl on the console's helpful too: openssl s_client -connect www.ste

Re: SSL certificate chain

2013-09-02 Thread Steve Wilson
On 2013-09-02 11:59, Daniel Lundqvist wrote: I have, it just says only 1 certificate is provided. Here are the test results: https://www.ssllabs.com/ssltest/analyze.html?d=www.malarhojden.nu ... I note that you're using startcom for the certificate, I recall that the intermediate certificate t

Re: Add [nginx] to subject lines on this mailing list?

2013-05-16 Thread Steve Wilson
On 2013-05-16 16:07, Daniel Griscom wrote: At 3:34 PM +0200 5/16/13, René Neumann wrote: Am 16.05.2013 15:18, schrieb Jim Ohlstein: I think what Maxim was alluding to is that any decent email client will sort messages for you based on headers if you set it do do so. This way you don't need to sca

Re: location matching.

2013-05-12 Thread Steve Wilson
The good news is it looks like subversion clients support SNI so I've got a new server block which is now working great. server { listen 80; ## listen for ipv4 listen 443; ## listen for ipv4 listen [::]:80; ## listen for ip

Re: location matching.

2013-05-12 Thread Steve Wilson
On 12/05/2013 16:34, Jonathan Matthews wrote: > On 12 May 2013 16:21, Steve Wilson wrote: >> On 12/05/2013 15:55, Jonathan Matthews wrote: >>> Have you looked at the ^~ prefix mentioned in >>> http://wiki.nginx.org/HttpCoreModule#location ? >>> >>> It

Re: location matching.

2013-05-12 Thread Steve Wilson
On 12/05/2013 15:55, Jonathan Matthews wrote: > Have you looked at the ^~ prefix mentioned in > http://wiki.nginx.org/HttpCoreModule#location ? > > It looks like what you need ... I thought I'd tried that, and even with the change in config it's still giving me the 404 errors. changed config:

location matching.

2013-05-12 Thread Steve Wilson
I've just had to move subversion onto a server that's already serving network wordpress via nginx. Most things work via /svn in a subversion client but I can't for the life of me figure out how to stop /svn.*\.php hitting the fastcgi_pass. I'm sure it's simple and I'm just not seeing the wood for