4. Hosting - mattstras/cs329e-idb GitHub Wiki

Projects 3 and 4 (Github pages):

For projects 3 and 4, we hosted the site using GitHub pages using the domain mattstras.github.io following the brief tutorial provided by GitHub. We created an account on namecheap to register the free domain politic329.me so that our site would have a domain more in line with the content provided. On the 'advanced DNS' page of name cheap, we updated the CNAME to point to mattstras.github.io and created a CNAME file in the repository to point to politic329.me.

Project 5 (Digital Ocean):

For this iteration of our site we created an account on Digital Ocean and paid for a droplet server. Hosting with Digital Ocean allowed us to create our website using a python framework allowing for easier and more professional site design. We used the provided tutorials to initialize the server and link to our GitHub repo.

Setting up the digital ocean server required the installation of apache2, wsgi, flask, and virualenv on the server. With these tools we were able to create a virtual environment on the server that could run python code. Cloning our repository onto the server then allowed us to be able to run the app.py file in our repository initializing the site and bringing it online. After this, our site could be accessed by using our ip address.

Since we already had a url provided by namecheap for the previous two projects, we sought to link the domain name with our digital ocean server. To do this, we had to update some name servers on our namecheap domain page, and then add a cname type dns record to digital ocean that would recognize our domain name. We ran into an issue here as we lacked the type A dns record as the tutorial didn't mention setting one up and we didn't already have it. Creating this record after hours of thinking it would just take a bit more time to update in the system solved this issue and we could finally access our site on digital ocean with our domain name, politic329.me.