Skip to content

skarzi/jenkins_configuration

Repository files navigation

Jenkins configuration as a code

lint dockerhub

Jenkins master configuration as a code for my personal Jenkins instance.

Deployment

docker and docker-compose is needed to deploy Jenkins master with docker-plugin cloud.

Environment variables

Firstly run following command to populate environment variables:

cp -R .envs/.dist .envs/.production

Then edit it carefully and fill all required values (environment variables with !!SET_VALUE!! value):

  • .envs/.production/.master:
    • VIRTUAL_HOST - Jenkins' master host

Secrets

Populate all secrets defined in docker-compose.yml:

  • .secrets/admin_password - Jenkins' admin password
  • .secrets/docker_hub__skarzi - properly encrypted by Jenkins, personal access token or password to skarzi docker hub where Jenkins' slave image is hosted

Docker compose override

Create docker-compose.override.yml:

cp docker-compose.override.yml.example docker-compose.override.yml

Now fill all required values (with !!SET_VALUE!! value) inside newly created file:

  • DOCKER_GID - docker group GID from your system. You can get this value by checking it in /etc/group file or running following command: getent group docker | cut -d : -f 3

Run services

Use docker-compose to run Jenkins' master and slaves behind nginx reverse proxy.

About

Jenkins master configuration as a code

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •