#known 2016-05-30

2016-05-30 UTC
tantek and loic_m joined the channel
#
knownchatwelcome
Welcome loic_m! The channel is pretty quiet right now, so I thought I'd say hello, and ping some people (like benwerd, mapkyca, and kylewm) that you're here. If no one responds for a while, try posting on our development mailing list at https://groups.google.com/forum/#!forum/known-dev or just try coming back later.
rMdes joined the channel
#
rMdes
anyone around ?
#
rMdes
got an issue with my nginx I think http://rmendes.net/s/JKoP
#
knownchatwelcome
Welcome rMdes! The channel is pretty quiet right now, so I thought I'd say hello, and ping some people (like benwerd, mapkyca, and kylewm) that you're here. If no one responds for a while, try posting on our development mailing list at https://groups.google.com/forum/#!forum/known-dev or just try coming back later.
#
rMdes
it seems my url's return a /index.php/ that should not be even there
raretrack joined the channel
#
kylewm
rMdes: want to share you nginx config?
#
rMdes
2 sec, login in
#
rMdes
wow it's not nginx my bad
#
rMdes
it's good old htaccess
#
rMdes
and it's on a shared hosting
#
rMdes
i think i'm using the default htaccess, maybe not the latest, not sure if it changed over versions
#
rMdes
I think the culprit is this line here : RewriteRule ^(.*)$ %{ENV:BASE}/index.php?/$1 [L,QSA]
#
rMdes
but I'm not confortable at all with htaccess
#
rMdes
I don't know if I can just remove index.php from that line and have it like RewriteRule ^(.*)$ %{ENV:BASE}/$1 [L,QSA] ?
#
kylewm
that seems strange to me, I didn't expect rewrite rules would *redirect* to /index.php
#
rMdes
i just checked the original htaccess-dist and it also have this line
#
rMdes
my htaccess just have a few lines to force HTTPS
#
rMdes
very strange when I click the short link from facebook syndicated copy I get the error
#
rMdes
if I click the link you just gave (witch is the same theorically) it works indeed
#
kylewm
the redirect from http://www.rmendes.net/s/JKoP to https is what's adding the index.php
#
rMdes
hmmm so I may be using a rule that appear to work, but it's not 100% case scenario
#
rMdes
i think my problem is having 2 specification to force HTTPS
#
rMdes
the one at the top with ps:env HTTPS and the one at the end : RewriteEngine On
#
rMdes
RewriteCond %{HTTPS} !=on
#
rMdes
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
#
rMdes
I guess I have not yet finished to find the best htaccess set of rules to fix this HTTPS thing
#
kylewm
you could try asking bear in indiewebcamp ... he's the expert on this stuff :)
#
rMdes
thanks kylewm i'll ask him
#
rMdes
I think dreamhost added one line to achieve that and I added another one
#
rMdes
so I commented everything until i find the best rule to force https always
#
kylewm
rMdes: oh you know, it's a holiday in the US, he might not be around
#
rMdes
of course no worries
#
rMdes
i'll stay around and experiment from a clean htaccess
#
rMdes
there is so much opinions about this on google that it's actually difficult to know what tutorial to follow
#
kylewm
yeah no doubt
#
kylewm
maybe trying adding the 'L' flag to the https rule to get it to stop after applying it
#
kylewm
RewriteRule ^(.*)$ - [L,env=ps:https]
#
rMdes
trying now
#
rMdes
thanks
#
rMdes
kylewm, i found the real culprit
#
rMdes
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
#
rMdes
but that's chinese to me, but that's what actually enforce HTTPS on my host
#
rMdes
not the env:ps https at the top (i commented those lines now to isolate the issue)
tantek joined the channel
#
kylewm
oh way down at the bottom, i didn't even see that one
#
rMdes
kylewm, i'm able to enforce HTTPS using other instructions, clearly proposed by Dreamhost itself
#
rMdes
but can't avoid this index.php when coming from HTTP
#
kylewm
huh, yeah I'm not sure, I don't know apache very well
#
rMdes
i'm still digging will find out
loic_m, rMdes_, tantek and rMdes joined the channel