September 20, 2019

Go: Spin-Up Databases for CI Testing

One thing has always bothered me while writing tests is the lack of a real datasource to run tests against. Most projects I’ve worked with in the past have either mocked responses from a datastore or used a “common” datastore to perform tests against. While mocks are good for quick unit tests, I still prefer using a “real” datasource, especially for integration tests. While taking Bill Kennedy’s Ultimate Go training a while ago, I saw Bill recommend a testing approach which involved “spinning up” a database container right from within your test code, run your tests, and clean-up. Read more

February 19, 2018

Caddy! Team 443 FTW

This one is a gamechanger. It really is. On a recent Golang obsessed Github browsing spree, I read the following project description: “Fast, cross-platform HTTP/2 web server with automatic HTTPS”. I’ve read that before, and more often than not ended up disappointing myself and resorting to hacks like [this] (https://blog.tux-sudo.com/posts/letsencrypt-nginx-docker/) to create an automatic TLS system for my websites. There are other ways, but almost all of them were semi-automatic in the long run (yay cron! Read more

September 26, 2017

LetsEncrypt Certificates for Dockerized Nginx

I like nginx. I like docker. I like SSL. I also like not paying for SSL certificates. If you, like me are operating a small time website, you probably don’t want to dish out a few hundred dollars for an SSL certificate.Thankfully, LetsEncrypt provides free ssl certificates and is now trusted by most major browsers. However, integrating certbot to automatically configure my nginx inside a docker container has been a pain. Read more

Powered by Hugo & Kiss.