phpmyadmin on apache behind https nginx

Umesh Sirsiwal usirsiwal at verivue.com
Wed Jul 13 23:07:32 MSD 2011


You might want to take a look at:
http://wiki.nginx.org/HttpProxyModule#proxy_redirect


On 07/13/2011 02:53 PM, Gelonida wrote:
> Hi Jim,
>
> Thanks for your answer,
>
> On 7/13/2011 8:27 PM, Jim Ohlstein wrote:
>> server {
>>       ...
>>       listen 80;
>>       ...
>>       location /phpmyadmin {
>> 	rewrite ^ https://yourhost$request_uri? permanent;
>>           ...
>>       }
>>       ...
>> }
> OK if I add above location rule in my http server,
> then all phpmyadmin requests on my http server will be redirected to my
> nginx https server.
> I learnt something new. :-) ( Never used rewrite rules so far )
>
> However my main problem is that
> I enter https://hostname/phpmyadmin/index.php in my browser
> and that phpmyadmin issues 301 with
> http://hostname:8080
>
> the hostname is substituted correctly, but the protocol and the port
> number are the ones from my proxy_pass command.
>
> proxy_pass http://127.0.0.1:8080
>
>
>
> Perhaps this problem disappears if I would use fastcgi.
> However the current php version installed on my server wasn't compiled
> with the cgi option :-(
>
>
>
>
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://nginx.org/mailman/listinfo/nginx




More information about the nginx mailing list