3 ms·
I would not suggest this book to people who want to practice professional software deployments in 2021. This book is setting you up with a limited set of skills
by throwaway984393 5y ago
I would not suggest this book to people who want to practice professional software deployments in 2021. This book is setting you up with a limited set of skills that are over-complicated and not best practice. For instance:
Server configuration. You should not be monkeying around with OS configs. If you do, it should only be in something like a Docker container, which is an easily tested/updated versioned immutable repeatable closed environment that runs everywhere. Monkeying with server configuration is a quick path to becoming a systems administrator, introducing unnecessary bugs, and increasing complexity. Try to avoid using software that is platform-specific (see next point).
Services with systemd. You should probably not use systemd to manage services. The primary reason is that you might not fully control the system you run services on if it's a multi-user system, and you need to have system control to modify systemd. It's also generally not portable outside of a Linux system. In the cloud you would ideally be using a deployment or orchestration system which has its own configuration format and method to run services, obsoleting systemd. The most portable service manager you could learn to use would be runit (even Busybox has an implementation of it), and after that, whatever one you choose that you can run as an unprivileged user. You can then run your preferred service manager as a systemd service, or in a container, etc.
Databases. Try not to get into monkeying around with backups and restores. Find some kind of managed provider that can do simple snapshots before deployments and easily restore them. Doing it manually is painful, and automation could be done better by a managed provider than trying to roll it yourself. However, you should be familiar with Flyway-style database deployments.
SELinux. You should not have to learn how it works to deploy. But if you do, get a dedicated book on it.
Storage concerns. Don't use networked filesystems for production. You can, in the sense that you can toast bread in the bathtub, but I wouldn't recommend it.
Backups and restores. Use versioned immutable artifacts in an artifact repository. Use a managed backup service/tool/etc for whatever doesn't work that way.
I don't see mention of caching proxies, reverse proxies, or CDNs. These can get tricky, from being careful about headers to preserving source IPs to invalidating stale caches to load balancing and resource limits.
I don't see any mention about continuous deployment, continuous integration, the 12 Factor App, or Immutable Infrastructure. All these are core components of modern deployments.
And as much as I hate it, Kubernetes is slowly of eating the entire world of modern systems, so learning how deployments work on it is essential to working in modern professional settings.
- jalino23 5y agothank you so much for this!
- surajs 5y agowhat would you recommend in its stead? for a similar audience
- throwaway984393 5y agoI'm not sure there is one really, because deployment varies a lot depending on your technology stack, your architecture, your deployment model, your product. You sort of learn the fundamental concepts and then pick out the pieces that fit your use case. Everyone should read Continuous Delivery to start (https://www.amazon.com/gp/product/0321601912/ref=as_li_tl?ie=UTF8&tag=devopslinks0e-20&camp=1789&creative=9325&linkCode=as2&creativeASIN=0321601912&linkId=3b5500da5130639b20ab323f314722a9 https://www.amazon.com/gp/product/0321601912/ref=as_li_tl?ie...). It's 10 years old but it's still the canonical reference for how most people should be deploying in the modern age. A book on containers would be the next thing I'd learn very thoroughly. Whether you run them in Docker on a single host, or run them in a cloud orchestration system, doesn't matter really. Just having an app in a container provides the abstractions you want to enable rapid, reliable deployment on multiple platforms. Most deployments should be dead simple: pulling and starting a new container, pointing traffic at the new container, stopping the old one. Rollback is the same in reverse order of container. There should be a billion different services to manage this for you, but you can also do it yourself on a single Linux box easily. Then a book on database migrations, which isn't really complicated once you get the jist of it. This teaches the idea that if you're using a database, you have to think hard about how you're using it in context of your code deployments, and gives you a model for how to handle both reliably. Next, the tools Terraform and Packer are very useful for handling the "infrastructure" side of deployment. If you manage an actual VM that runs your apps, build the image with Packer and deploy it with Terraform. It's much better to use some managed provider that just runs your containers so you don't need to deal with this. But if you do need to manage a host OS, this will make it seamless and reliable to do the inevitable maintenance in a way that you can test first, and recover easily from failure. Ensuring your app works along the methods of the 12 Factor App (it's just a website, no book) will make sure it fits into all the tools and methods. If you just look for the deployment piece of every part of 12FA, you'll build a very robust deployment system. Finally, learn Bash and how to set up a web server like Nginx (and how to use it as a reverse proxy) and you will have basically all the skills you need to do modern best practice deployments.