About
Video Showdown is a website where you compete with friends in submitting videos for a given topic.
The Tournament owner creates rounds with themes, for example "Cat Videos". Players submit videos that match the theme, and then vote and comment on other submissions.
Screenshots
What I Would Do Differently
Draw out the pages with pen and paper
I started by working mainly on the backend and figuring I would just use a simple front end. This led me to not think about what each page really needed, which meant I had to go back and add a lot of stuff when time came to make a nice UI. Drawing out each page on paper would have gotten me to think about exactly what each page needs without the hassle of trying to make nice HTML/CSS.
Make admin tools early on
I made the admin tools towards the end, and during development used printfs and SQL statements to inspect and change the state. This isn't too bad, since the site's logic is simple and the majority of the work is making the medley of web technologies mesh together. However, it would have sped up debugging time greatly, and I knew I was going to make admin tools eventually.
Not use MariaDB
I had some experience with MariaDB before, and chose it over PostgreSQL as people say there's less of a learning curve. The downside to MariaDB is that it produces nearly useless error messages. All it tells you is where in the code it failed. In the case of running scripts it doesn't even do that correctly as the internal line number resets with every new statement. Even if PostgresSQL takes a bit to learn I bet it pays off since you'll waste less time trying to figure out what the problem even is, and you will be less annoyed.
I had heard that running your own email server was a pain, but I always figured it couldn't be that hard. After setting up email for this project I know what they mean. None of it was hard, but there are many things you need to configure and get working together. Email was invented in 1982, and in the decades since then an accretion of add-ons have turned email into a giant mess.
Initialisms You Should Know
- SPF/DKIM/DMARC: how recipients know you aren't spoofing your emails
- SSL/TLS: in transit encryption
- SMTP/MUA/MSA/MTA/MDA: mail sending and delivery
- POP3/IMAP: client-server connection
- SASL and STARTTLS: starting client-server connections
- LDA/LMTP: MTA-MDA communication
- S/MIME: at rest encryption
You don't have to understand these things in too much depth, but you need to know how they work together so you can get your email system working. Again email isn't exactly hard, but there is a lot of configuring to do and a lot of configuration languages. If you were to remake email today it would be a lot simpler.
Other things you should be aware of fail2ban: time ban on multiple failed login SpamAssassin/Sieve: spam filtering
Spam Lists
After you get the technical side working your emails will likely either not get delivered, or get sent to the spam box. This is because the IP address you are using likely was used to send spam in the past. Some spam lists have a process where you can request removal, but some spam lists are simply extortion scams where you have to pay to be removed from the list.