How can I map a docker location to my Jenkins workspace so that I can use the files in my Jenkins

+1 vote

Hey guys,

I was trying to execute few files from my container which are 2 html files which I can later  publish on Jenkins. As my Jenkins is hosted on one host machine not in my local and we are using git . Have to run dockerfile.compose.yml and to do this. My container is a windows container. This is my below dockecompose file:

version: '3.5'



    container_name: alpineautomation

    hostname: alpineautomation


      context: ../..

      dockerfile: devops/k8s/


        GITSHA1: ${GITSHA1}

    image: alpineautomation


         - ./var/lib/jenkins/workspace/AlpineAutomation:C:\\ProgramData


         -  ./var/lib/jenkins/workspace/AlpineAutomation                                                                                                                              

Feb 25, 2020 in Docker by dineshkumar
• 130 points
So basically, you want to copy those 2 HTML files from a docker container to your Jenkins workspace. Is that what you are asking?
Do you want to mount Jenkins workspace in docker container using Jenkins pipeline? Are you referring to this?

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In Docker

0 votes
1 answer

How can I connect a docker container to two docker networks that I have created?

Hi@akhtar, It's correct that the network argument of ...READ MORE

answered Mar 23, 2020 in Docker by MD
• 95,300 points
0 votes
2 answers

How can I inspect the file system of a failed `docker build

Failed command is a build that has ...READ MORE

answered Aug 6, 2018 in Docker by Nilesh
• 7,040 points
0 votes
1 answer

Can you use docker-compose files to start services in Docker 1.12 swarm-mode?

Yess, you can. you must download/install the ...READ MORE

answered Aug 10, 2018 in Docker by Kalgi
• 52,370 points
0 votes
1 answer

Can I give an advance instructions to run later, during the next build stage in docker?

You can definitely give a trigger instruction ...READ MORE

answered Jul 2, 2019 in Docker by Sirajul
• 59,070 points
0 votes
1 answer

How to configure my docker container to use a different logging driver?

When you start a docker container, you ...READ MORE

answered Jul 4, 2019 in Docker by Sirajul
• 59,070 points
0 votes
0 answers

How to invoke a Docker secret key in c# console application? I want a sample code for it.

Actually I want hide a salt key ...READ MORE

Mar 20, 2020 in Docker by anonymous
• 120 points
0 votes
1 answer
0 votes
1 answer