Hopefully a quick question about setting up a rather hacky container for developing various web applications at my company, +Tribalogic
For various reasons (mainly waiting for RHEL/CentOS 7 + systemd goodness) some of my hosted servers are still on RHEL/CentOS5. In my dev environment I run +Mageia.Org
but obviously this comes with much newer versions of various hosting infra (namely apache+PHP+mariadb for us).
In order to test things properly we really want our dev env to be as similar to the live env as possible. Some of our devs use OSX so for them I'll go down a VM route, but for those of us on Linux I'd rather set up a very lightweight container with as small an overhead as possible.
Ultimately bootstrapping CentOS in the container is fairly easy (there are a few quirks with yum/rpm on Mageia being newer and thus writing different rpm db than CentOS can read, but that's simply enough to work around after the container is created). But I guess my question is the best way to boot the container.
As it's old, it uses sysvinit. However, I don't really need to boot this container, I really just need to run httpd and perhaps one or two other services. I'm thinking that rather than using sysvinit, I could just hack a rather trivial script/program to spawn httpd and the other processes and wait for them to exit and just call this "init". I could also hack up rc.sysinit appropriately (i.e. kill 99% of it) and still use sysvinit binary and perhaps just put my needed stuff in inittab rather than worrying about the whole runlevel+rc.d folder thing.
Obviously it would be nice to run systemd inside the container too, but I think this is perhaps more effort than it's worth for now (and keeping in mind I intend to switch over to CentOS 7 at some point in the not too distant future).
Anyone have any simple ideas/hacks/tricks that I could employ here?