Giter Club home page Giter Club logo

Comments (4)

tkambler avatar tkambler commented on June 19, 2024

+1 - Cannot manage to make this work. Show stopper.

from docker.

michaelneale avatar michaelneale commented on June 19, 2024

This is by design - docker official image repos suggest NOT placing volume in the Dockerfile - as it can't be removed by dependent dockerfiles. You can have a Dockerfile with FROM jenkins at the top - and then VOLUME as needed.

However - using -v /local/path:/internal/path is a different issue (the PR) - I get the feeling there is general confusion with how docker works. Putting -v /volume/here is the same as VOLUME in dockerfile (wthout the limitations) - which is different again to -v /host/path:/volume/here.

from docker.

dkapanidis avatar dkapanidis commented on June 19, 2024

Hi,

can you put a reference to the suggestion of not placing volumes in the Dockerfiles?

It's true, volumes can't be removed by dependent Dockerfiles, but that's by design. I can't think of a use case that it is necessary to keep the data inside a living jenkins container, that would break any possible upgrading patterns.

In general, most official repos do have a volume defined, so that the data are stored separately from the container. I put some examples below:

my 2cents

from docker.

michaelneale avatar michaelneale commented on June 19, 2024

It was in an email from official image approvers.

If those other ones are doing it, then we should here too, I agree.

The main problem is that people aren't reading the docs on docker volume
management.

On Saturday, September 27, 2014, spiddy [email protected] wrote:

Hi,

can you put a reference to the suggestion of not placing volumes in the
Dockerfiles?

It's true, volumes can't be removed by dependent Dockerfiles, but that's
by design. I can't think of a use case that it is necessary to keep the
data inside a living jenkins container, that would break any possible
upgrading patterns. (

In general, most official repos do have a volume defined, so that the data
are stored separately from the container. I put some examples below:

my 2cents


Reply to this email directly or view it on GitHub
#9 (comment)
.

Michael D Neale
home: www.michaelneale.net
blog: michaelneale.blogspot.com

from docker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.