/home/e

[+] Menu


[Server Misconfiguration Time!]

Server Misconfiguration Time!

Project

God I hate nginx. The sheer amount of files on top of files to sort through, writing them, debugging them, it's just a whole annoying process.

Migrating to this new server was a pain, at first I thought, "Oh! This would be a good oppurtunity for using docker to make everything simpler" and it did for the most part but something always has to go wrong.

I moved from OVH and DigitalOcean to a cheaper but better for value AlphaVPS, I have two domains, including this one. My credit for digitalocean was running out from the github education pack so I had to move fast. I was aiming to also transfer all of my services onto docker containers as it was easier to set up and containarised. I already mocked up the compose file during university but just didn't have the time.

The most concerning thing was keeping my matrix synapse files intact, so I could keep the messages between me and my friends, everything else didn't really matter.


Initially, the server broke instantly. I rented it out, and it didn't start for a few hours until their team fixed the issue. After that I didn't really have many issues server-wise but still left a sour taste but we all have tech problems.

I used letsencrypt certbot to generate the certificates for the ports which use ssl, that was straight forward and the least painful part of the whole process.

I setup the directory structure and downloaded the backup of my old OVH server, and placed the important files in the correct locations. The first issue was the docker compose file, I incorrectly formatted area but wasn't too difficult. When actually starting it, everything was breaking due to permissions being wrong, fixed it soon after.

I was trying to set up the matrix server, but due to the config not being in the correct format the docker version wanted, it was giving me permission denied on actually running it even though the permissions were correct. I used diff between a docker config and a baremetal config and edited it to be as close to the other, however this did not do anything.

The one thing I wanted to keep intact was ruined :c

I created a new config, set up the matrix server and let it run, it actually started up. I couldn't access it because of not setting up nginx yet.

I used to have a good relationship with nginx, I thought it was rather easy to set up, but when you have seven different services to set up, it's a pain. Docker made it fairly easy as you can just reference container names and be able to access them.

Originally I had matrix run on localhost port 8008 and mapped to 8448 (SSL) with nginx with my personal website on 80 and 443 (SSL)

Written by E. Published on .