Tag: jenkins

Why can't docker commit a Jenkins container with customized configuration?

I pulled a Jenkins image and launched it. Then I did some configuration on that container. Now I want to save all my configuration into a new image. Below is the command I used: $ docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES f214096e4847 jenkins “/bin/tini — /usr/lo” About an hour ago Up […]

Unable to run android emulator inside Docker container

I’m trying to run android emulator to run some tests on it. I’ve got a Docker container containing Android SDK with build tools, platform tools and so on. I’ve successfully created AVD: jenkins@b4c6c9cee181:/$ android list avd Available Android Virtual Devices: Name: hudson_de-DE_160_HVGA_android-24_armeabi-v7a Path: /home/jenkins/.android/avd/hudson_de-DE_160_HVGA_android-24_armeabi-v7a.avd Target: Android 7.0 (API level 24) Tag/ABI: default/armeabi-v7a Skin: hvga Sdcard: […]

How to run a docker image in jenkins which is already in Docker Container

I need to run my own docker image in jenkins pipeline job and my jenkins is already running in a container? Is there any possible way to do it?

How do you provide a managed file to a Jenkins build using docker.image?

I am trying to use Jenkins Pipelines to build a Maven Java project and deploy its artifacts into Nexus. The Nexus credentials are managed by Jenkins, so I need Jenkins to provide the Maven settings.xml file. My pipeline uses docker to run the build. My Jenkinsfile looks like: node(‘docker’) { git ‘git@bitbucket.org:myorg/myproject.git’ stage ‘Build and […]

Where does inherited jenkins container allow additions to VOLUME

Here’s my Dockerfile, which builds upon the Jenkins docker setup: FROM jenkins:latest USER jenkins COPY ./mystuff/ /var/jenkins_home/jobs/ COPY ./config/plugins.txt /usr/share/jenkins/plugins.txt ADD ./config/plugins.txt /usr/share/jenkins/plugins.txt RUN /usr/local/bin/plugins.sh /usr/share/jenkins/plugins.txt I realize that /var/jenkins_home is defined as a VOLUME in the parent image/container. Based on that, I expected that the contents of directory mystuff would NOT get added to […]

Jenkins docker pipeline error

I’m trying to follow this tutorial to create a simple docker environment in as part of my jenkins pipeline build. I’m trying to build a couple of docker images just as a test before I do my maven build. At the moment I have the following groovy for my Jenkinsfile: #!groovy node { stage ‘Building […]

Jenkins, Docker Build Step create container issue

I try to create a job creating a docker container using Docker Plugin. Soft versions : Docker version 1.12.3, build 6b644ec Jenkins version 2.34 Ubuntu 16.04 I set all needed permissions to jenkins user jenkins@myServer:~/jobs/createDockerContainer$ groups jenkins docker Also I have enabled Docker Remote API sudo netstat -an | grep 4243 tcp6 0 0 :::4243 […]

Python: running docker containers with sh and handling UTF-8 decoding errors

I have a Python program that is directly executed by Jenkins. This program uses the sh library to execute a docker container, via this function. Note that it is an important feature of this function that it display the subprocess‘s output as it executes: def run_command(*args, **kwargs): # pass the parent stream ‘tty’ state to […]

Maven build with parameter somehow cache parameter in war?

i’ve encountered problem with different behavior on different environment with same application. Let’s begin: I’m building application through Jenkins pipeline, where firstly i’m using mvn install to create war, with parameter with database port DBD_PORT to connect to while integration testing: mvn clean install -DextConfig=${env.WORKSPACE}/<appPath>/<appTestsIT>.properties -Ddb.port=${DBD_PORT}” then i’m using war created through this command and […]

Adding Jenkins Pipelines on Build

does anyone know if its possible to add a Jenkins pipeline build into a Jenkins docker image? For example, I may have a Jenkinsfile that defines my pipeline in groovie, and would like to ADD that into my image when building from the Jenkins image. something like: FROM jenkins:latest ADD ./jobs/Jenkinsfile-pipeline-example $JENKINS_HOME/${someplace} And have that […]

Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.