I have a relatively simple understanding of GitLab CI:
- There is a GitLab server (server A)
- There is a separate server with GitLab runners (server B)
- And there is some other server - the 'prod' server (server C)
From prior experience, I understand that the GitLab runners would do the following:
- On a push to source control, GitLab (server A) would contact the GitLab runner (server B), and the runner would pull the source control and execute jobs as defined in
.gitlab.ci-yml, which is included in the source control
- As defined by the
.ymlfile, a Docker image would be added back to server A (to the GitLab Docker registry). Then the runner would login to server B, pull the docker image, and start it.
I am opting for a simpler automated deployment setup.. I want 2 servers:
- Server A (GitLab CE)
- Server B: Ubuntu 18 server that has a GitLab runner, AND that serves as a production server
Is this a good idea?
It seems like I can configure the runner to just run a
docker-compose up --rebuild command, and that this would essentially work.
Is there any reason that I wouldn't want to do this?