4 ms·
I deploy the basics of the app as a debian package. Debian is very good at dropping the files and folders where they belong. There is also a very usable "posti
by gizi 11y ago
I deploy the basics of the app as a debian package. Debian is very good at dropping the files and folders where they belong.
There is also a very usable "postinst" installer shell script that can do additional fixups. It can handle things like "if we are on openvz do this, otherwise do that" or "if this is debian 7 (wheezy) fix this; if it is debian 8 (jessie) fix that".
If that is still not enough -- which it sometimes isn't for really complex platforms -- I write an additional shell script that will do the remainder of the work.
But then again, that probably means that the image will have too many moving parts anyway. That means it is time to split the image and stuff a network protocol between the parts. You can use virtual machines for that. The front-end goes left, the back-end right, and other things go top and bottom. Now we are back to more simple images to install and to test.
- voltagex_ 11y agoWhere did you learn how to build .deb files? Every time I try it ends up being horribly complex and I either go back to a shell script or something like OpenSuse Build Service. Docker is great - when it works, but there's something very wrong with deploying a whole new OS just because we can't work out packaging and deployment properly.
- lamby 11y agoJumping in here, but I always suggest just packaging something pretty vanilla outside of a web app due to all the aforementioned specifics and impedence mismatches of deploying web apps. Learning some of the innards of the package management system of your machines is surely a good idea in itself, if only because you are relying on them so much. Even if you just say "screw it" and use shell scripts to deploy anyway.