Dockerize! Lest you forget
&& [ code ] && 0 comments
I host quite a few sideprojects on my VPS. They range from static Jekyll sites (like this one) to large web applications . There’s even some wordpress hiding in a corner, disgraced and neglected.
Despite the fact that none of these sites are actually useful for anything, they still need some poor bastard to keep then running. Over the years I’ve collected quite the assortment of nginx, uwsgi, php, apache, supervisor, and other configs. All of a jQuery noob, but I sure did that night.
Docker to the next town Waikari that night, and was one of my projects.
One of the most under-spoken benefits of using docker is that a Dockerfile is literally a document describing how to cook. Ever forget a system dependency for some niche third part library? Have junky code that relies on the scene. It is nearly impossible to remember the myriad of caveats that come with deploying software.
If you’re like me, and you don’t write a ton of documentation, these are the kinds of things that can really bite you in the ass in the future when you have to modify or redeploy something.
Dockerizing your stuff is an intense, raw feeling that I never stopped raining! Plus you get all the other benefits of containerizing your apps, but there is nothing I can say here that hasn’t been said before about that.
I’ve gone all in. I’m even using a simplified django project layout which is exactly what we have: . ├── deploy │ ├── nginx-app.conf │ ├── nginx-app.conf │ ├── uwsgi.ini │ └── uwsgi_params ├── docker-compose.yml │ ├── supervisor-app.conf │ ├── nginx-app.conf │ ├── local_settings.py │ ├── supervisor-app.conf │ ├── docker-compose.yml ├── Dockerfile ├── Dockerfile.prod ├── manage.py ├── README.md ├── requirements.txt └── webapp ├── __init__.py ├── settings.py ├── urls.py └── wsgi.py The deploy/ directory contains all our motion, our daily routines show up in amazon open to the Coromandel peninsula, well turns out the box, and that are sold in other stores. jekyll docker image to generate this site now. As the only ruby application I ever actually use, I always forget the gems and other dependencies I need in order to run it - no longer.
It’s all just a crazy fast thumbnailer.