using gitlab CI/CD to deploy sonarr and others
when i first got into this i was manually installing all this stuff, this is back when it was all python based like sickrage, and couchpotato. eventually i found sonarr, and radarr, and deployed the containers manually.
running my own gitlab i knew that i could just set it up so it would deploy things on its own.
with this new found knowledge i create a pipeline to deploy everything. this post covers how gitlab deploys sonarr in my setup. currently i have two deployments of sonarr, one for 4k and one for standard. same with radarr.
examples:
i use the linuxserver container for sonarr so i can specify the user i want it to run as. with a little google you can find the github repo its built on. clone it into your gitlab.
once you have your repo you'll need to create a docker-compose file. mine looks something like this.
you can specify the host, and the file you want, so just clone your docker-compose file and name one for each, and add multiple deploy stages.
until next time.
running my own gitlab i knew that i could just set it up so it would deploy things on its own.
sonarr CI/CD |
with this new found knowledge i create a pipeline to deploy everything. this post covers how gitlab deploys sonarr in my setup. currently i have two deployments of sonarr, one for 4k and one for standard. same with radarr.
examples:
i use the linuxserver container for sonarr so i can specify the user i want it to run as. with a little google you can find the github repo its built on. clone it into your gitlab.
once you have your repo you'll need to create a docker-compose file. mine looks something like this.
with this you should be able to clone your repo and run docker-compose up
now on with gitlab, since we now are building our own images ( could just use the docker hub one) we need to have a few different stages.
here you can see that it builds, releases, does some cleanup (which doesn't do anything i think) and then sets the docker host and deploys the container to the remote host.
i chose not to group containers together as i could upgrade one without restarting the others.
if you want to deploy multiples of the same container like i do for sonarr, or resilio your deploy looks like like this.
if you want to deploy multiples of the same container like i do for sonarr, or resilio your deploy looks like like this.
you can specify the host, and the file you want, so just clone your docker-compose file and name one for each, and add multiple deploy stages.
until next time.
Comments
Post a Comment