Assumed that readers have preliminary knowledge of docker, docker-compose, gitlab, CI/CD and network.
- Network along with docker is very important.
- Should know how docker network works.
- It uses many container images from docker hub to achieve the goal that spring boot app can be deployed in docker container and be secured.
- Maybe a lot of things were skipped such as port-forwarding, setting ssh, etc..
- Skipped.
- I used
~/docker-compose
as the location. cd ~
mkdir docker-compose
cd docker-compose
vim docker-compose.yml
docker network create nginx-net
docker-compose up -d
- Or using zsh with docker-compose plugin,
dco up -d
- Maybe already settled in
docker-compose.yml
docker exec -it gitlab-runner bash
- Execute
gitlab-runner register
and complete following prompts. - Press
Ctrl + p + q
in order to exit from container shell safely.
- Put
Dockerfile
and.gitlab-ci.yml
on the root directory of spring boot project.