Do you run a salt minion inside a docker containers?
Or do you only run a minion on the server which runs the docker containers?
We don't use salt at the moment, but want to use it in the future.
We are unsure how to layout our infrastructure in the future.
Please leave a comment, if you don't understand my question :-)
You can do either or both. The two options have different purposes. Here's different ways you could use configuration management:
Rather than writing a more complex Dockerfile to install and set up your code, your Dockerfile just says something like
FROM saltstack/ubuntu-14.04
RUN salt-call <...>
This might be good if you're looking at transitioning from Salt-provisioned machines into using containers. Ultimately, I've preferred to use the Dockerfile and not a config manager here because it's more transparent and I can take advantage of caching when I'm building the image during development.
There's two different philosophies with Docker. One is that you use a container like a sand-boxed application: one application per container and generally restrict inter-application communication to TCP. The other is that you treat containers like little machines, provisioning multiple applications on one container and run some initd-type service inside the container to keep them all running.
If you follow the latter style and want to update a running container, a minion inside the container is how to do it. (Personally, I prefer doing the former and rebuilding/restarting containers when I want to change anything.)
Finally, you might want configuration management on the host-machine to manage the containers (pulling, starting, stopping, and restarting). This would feel most familiar to you if you've done configuration management before, but there's a lot less configuration to manage because the dependencies and other application-specific configuration are all packed up into their containers.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With