Public | Automated Build

Last pushed: 2 years ago
Short Description
based on to support git, ruby, rvm and plugins with ssh access
Full Description

Setup Jenkins

setup docker with proxy

You must recreate the default machine or another to support proxies.
sh -c username:password -p proxy:proxyport

if docker login can't connect:
docker-machine env --no-proxy default
eval $(docker-machine env --no-proxy default)

pull vm

docker pull kaltepeter/jenkins

build vm (if building locally)

docker build -t kaltepeter/jenkins .

with proxy:
sed 's/^M$//' plugins.txt > plugins.txt

proxy=http://username:password@proxy:proxyport && \
docker build \
--build-arg HTTP_PROXY=$proxy \
--build-arg http_proxy=$proxy \
--build-arg HTTPS_PROXY=$proxy \
--build-arg https_proxy=$proxy \
--build-arg NO_PROXY=$(docker-machine ip) \
--build-arg no_proxy$(docker-machine ip) \
-t kaltepeter/jenkins .

start vm

docker run --name jenkins-custom -p 8085:8080 -p 2222:22 -e SSH_KEY="$(cat ~/.ssh/" -u root:root -v ~/data/jenkins_home:/var/jenkins_home kaltepeter/jenkins:v2

start jenkins

docker exec -i -u jenkins:jenkins -t jenkins-custom /usr/local/bin/

push code to machine

git remote add local2 ssh://docker@

git push local2 master


fix network

docker-machine restart default

eval $(docker-machine env default)

fix windows docker-machine with proxy issues


copy ~/data/jenkins_home to ./jenkins_home

Docker Pull Command
Source Repository