Automated deployment to Rancher

I have a repository on Docker Hub that is an automated build. The development process currently ends with the container build. I would like to extend this process into Rancher and automate the deployment into a specific environment/project. Is there a way to do that natively in Rancher? An external process would suffice as well. I am using Ansible to build the containers and could extend that to manage the deployment. Any direction or suggestions would be great. Thanks!

1 Like

Rancher-compose would be able to deploy services (multiple containers) into a specific environment/project within Rancher. It works just like docker-compose, where you have a docker-compose.yml and a rancher-compose.yml files. You would be able to do a rancher-compose up, which would deploy the services into a specific environment/project.

I believe that would help you start with what you’re looking to do.

Thanks! Would that imply a manual process and not something automated?

Ansible seems like the way to go.
I haven’t done this myself but it’s something I’ve been thinking about.
You could have it template a docker compose with enviornment specific settings and then run a command to start that up.
I’m personally hoping that docker label support gets into Ansible soon so that can be used to provision Rancher containers directly.

1 Like

@spacezio It sounds like you are wanting a way for rancher to have incoming webhooks. That way you can trigger it in a chain. Or am I misreading what you trying to accomplish?

@wizardofmath that would be the ideal method, yes. Failing that I was looking for an alternative method, for now we’ll likely extend our Ansible configuration.

@spacezio Re-reading this and thinking that maybe you are looking for this feature request: