kentonh / gPanel

A web-hosting control panel written in Go.
MIT License
80 stars 25 forks source link

Implemented TLS with autocert && partially fixed serving PHP #136

Closed george-e-shaw-iv closed 6 years ago

george-e-shaw-iv commented 6 years ago

This references #119.

I used autocert to implement TLS. Every client will get TLS by default through the use of this package thanks to LetsEncrypt.

When testing locally it seems that you're allowed to access the localhost:port versions of the client websites without having to authenticate through LetsEncrypt, which works out in our favor because if you had to it would be really annoying to contribute to this project.

While doing all of this I happened to figure out that PHP was actually kind of broken. I fixed it partially, it was just a header issue, but I also found out that post/get variables aren't working right now. I looked around and it seems that a bash script might have to be written to fix this problem, but I honestly have no idea where to start. The documentation for php-cgi is awful and all I can find is stackoverflow posts, such as this one and this one, with the latter I think being easier to use. I will put this information into a new issue after this PR merges.