diff --git a/Dockerfile b/Dockerfile index 2d51c2d..5dfb40e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,5 @@ FROM jenkins/jenkins:lts -MAINTAINER miiro@getintodevops.com +LABEL MAINTAINER="miiro@getintodevops.com" USER root # Install the latest Docker CE binaries diff --git a/README.md b/README.md index 3fc6a18..e8fc8dc 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,13 @@ # Jenkins CI with Docker binaries installed +## Usage + +### [Docker Compose](docker-compose.yml) + +To use docker compose run next command + +```shell +docker compose up -d --build +``` + +- `--build`: Flag to force build \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..dd57b50 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,28 @@ +version: '3.9' + +volumes: + jenkins-docker-certs: + jenkins-data: + + +networks: + jenkins_network: + +services: + jenkins: + image: jenkins/jenkins:lts + container_name: jenkins-controller + privileged: true + build: + context: . + dockerfile: Dockerfile + ports: + - "8080:8080" + - "50000:50000" + volumes: + - jenkins-docker-certs:/certs/client + - jenkins-data:/var/jenkins_home + - /var/run/docker.sock:/var/run/docker.sock + networks: + - jenkins_network + mem_limit: 4g