Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for passing build-time variables in build context #15182

Merged
merged 2 commits into from Sep 17, 2015

Commits on Sep 16, 2015

  1. Support for passing build-time variables in build context

    - The build-time variables are passed as environment-context for command(s)
    run as part of the RUN primitve. These variables are not persisted in environment of
    intermediate and final images when passed as context for RUN. The build environment
    is prepended to the intermediate continer's command string for aiding cache lookups.
    It also helps with build traceability. But this also makes the feature less secure from
    point of view of passing build time secrets.
    
    - The build-time variables also get used to expand the symbols used in certain
    Dockerfile primitves like ADD, COPY, USER etc, without an explicit prior definiton using a
    ENV primitive. These variables get persisted in the intermediate and final images
    whenever they are expanded.
    
    - The build-time variables are only expanded or passed to the RUN primtive if they
    are defined in Dockerfile using the ARG primitive or belong to list of built-in variables.
    HTTP_PROXY, HTTPS_PROXY, http_proxy, https_proxy, FTP_PROXY and NO_PROXY are built-in
    variables that needn't be explicitly defined in Dockerfile to use this feature.
    
    Signed-off-by: Madhav Puri <madhav.puri@gmail.com>
    mapuri committed Sep 16, 2015
    Configuration menu
    Copy the full SHA
    54240f8 View commit details
    Browse the repository at this point in the history
  2. incorporate doc review comments

    Signed-off-by: Madhav Puri <madhav.puri@gmail.com>
    mapuri committed Sep 16, 2015
    Configuration menu
    Copy the full SHA
    8cfcd87 View commit details
    Browse the repository at this point in the history