-
Notifications
You must be signed in to change notification settings - Fork 0
Build Image
Build the Docker Image without using cached versions of previous image build stages.
sudo docker build \
-f php-5-6-apache.Dockerfile \
--target build-php-56-apache \
--no-cache \
--build-arg NPM_VERSION=6.4.1 \
-t php-5-6-apache:latest \
.
-
Using
-f php-5-6-apache.Dockerfile
To specify
php-5-6-apache.Dockerfile
as the filename to build otherwise it is expected to be named justDockerfile
. -
Using
--target build-php-56-apache
To select the build target stage[^multi_stage_builds_note] from the Dockerfile.
-
Using
--no-cache
To prevent using previous cached versions of image build stages.
-
Using
--build-arg NPM_VERSION=6.4.1
To set build arguments & values to use during the build process.
NPM_VERSION=6.4.1
sets the Node Version to be used to 6.4.1 when rebuilding the image. -
Using
-t php-5-6-apache:latest
To name & tag the locally built docker image.
-
Using
.
To set the current location as the build context for the build process.