Out With The Old, In With The New

I've finally replaced my old website with a shiny new one. There were a couple of reasons I did this. The first reason is that I made the old website ~4 years ago when I didn't really know how to properly configure a Django project. This made it so the website was a lot more complicated than it had to be. For example I had multiple Django apps (in Django, an app is a grouping of similar models), which were completely unnecessary because I only wrote a couple of blog articles.

The second reason I updated my website was because the old Ubuntu instance I was using to run everything was very cluttered. I created the Ubuntu instance ~4 years ago when I didn't really know how to structure things. This made it so the source code which was running the various websites were in completely random directories. Imagine a server setup where the source code for one website is in one directory (following a certain set of conventions), and the source code for another website is in a completely different directory (following completely different conventions). And then there are tens of random directories from old websites that I no longer host. Because of this I didn't really know where any of the configuration files / source code would be when I'd ssh in and I'd have to spend a number of minutes getting reacquainted . Now I've set up things so they're simple.

Another reason I updated the website is because the text entry was a bit weird. Because my old website was hacked-together Python and JavaScript code, the text-editor was kind of janky. Typically when you have text input for a website or blog, you want to set up a 'WYSIWYG' editor (What-You-See-Is-What-You-Get). This allows you to input text as if you were using a dedicated text-editor like MS Word, instead of manually inputing in HTML. Well, with the old one I had to manually edit the HTML every time to add a special class to certain elements. Needless to say, it was annoying and now I'm just using a simple WYSIWYG editor without requiring me to do that.

// The syntax highlighting is kind of nifty as well.
// I was able to input this directly from the WYSIWYG editor.
function helloWorld() {
    console.log('Hey I can even put code in here!');

It's nice to be able to start from a clean slate. I've got quite a few projects in the works and I'd like to be able to document their developments on this website.

Tools Used

I might as well outline how I made this website.

For developing the website I used docker with docker-compose so I wouldn't have to install Postgres / other dependencies. The actual application is running Django 1.10. The webserver is Apache2 with wsgi.py to interface with Django. When I deployed I installed Postgres, created the role, database, password, etc., then I simply connected all of the various components and voila, now I have a working website.

For the WYSIWYG I am using a Django library called 'django-wysiwyg-redactor' and it seems to be working well so far.

The landing page animation (showing the gears moving) is a combination of some open source SVG gear vector images and CSS animations, nothing really complicated there.

I still need to get this website so it's SEO friendly and I need to start adding articles.

Anyways, stay tuned, I'm hoping to add content to this site in the near future!