Configuring https for this site, plus an announcement

25-12-2021

First of all Merry Christmas everybody, I hope you enjoy your holidays. This post will be a short one. I'll just announce something plus I'll show you how to properly configure https for your site if you are a fellow student here.

First of all the announcement. I added a services page where you can find other things I host here, for the time being it's just cinny, the best matrix client in my opinion.

Now for your https configuration. First of all we actually do have https for our sites here, but I only found out today. Thing is the http site just doesn't redirect you automatically to the https one. So the title is a bit clickbaity. I'll just show you how to automatically redirect from http to https. First cd in your public_html directory and create a file called .htaccess, now put the following in it:


  RewriteEngine On
  RewriteCond %{SERVER_PORT} 80
  RewriteRule ^(.*)$ https://www.cs.ucy.ac.cy/~<your-username>/$1 [R,L]
  

I'm not an expert when talking about apache, in fact this is my first time doing anything related to it so I might be wrong, however I found that this works a treat.