Wrap origin public Dockerfile to manage build args, etc

I’m very new to Docker and stuff, so I wonder if I can change source official and public images from Docker.Hub (which I use in FROM directive) on-the-fly, while using them in my own container builds, kinda like chefs chef-rewind do?

For example, if I need to pass build-args to openresty/latest-centos to build it without modules I won’t use. I need to put this

  • docker for windows mount a folder but can't open it after several hours
  • Remove docker images and containers that are taking disk space
  • How can I upgrade openshift origin if it is run as a docker container?
  • How configure python to get a qooxdoo build ok? [closed]
  • problems using Ansible to run docker tasks on OS X
  • Docker UDP port support?
  • FROM openresty/latest-centos

    in my Dockerfile, and what else should I do for openresty to be built only with modules I needed?

  • Automatically run a script when HBase master Docker container finishes initializing
  • How to uninstall Docker completely from a Mac?
  • App running in Docker container on port 4567 can't be accessed from the outside
  • Docker: HTTP code 403 while uploading metadata: “invalid character '<' looking for beginning of value”
  • Proper way of reporting performance data for C# application in a Container (Docker)
  • Default path to install Nexus Docker Container from AWS EC2
  • One Solution collect form web for “Wrap origin public Dockerfile to manage build args, etc”

    When you use the FROM directive in a Dockerfile, you are simply instructing Docker to use the named image as the base for the image that will be built with your Dockerfile. This does not cause the base image to be rebuilt, so there is no way to “pass parameters” to the build process.

    If the openresty image does not meet your needs, you could:

    • Clone the openresty git repository,
    • Modify the Dockerfile,
    • Run docker build ... to build your own image

    Alternatively, you can save yourself that work and just use the existing image and live with a few unused modules hanging around. If the modules are separate components, you could also issue the necessary commands in your Dockerfile to remove them.

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