Top "Dockerfile" questions

A Dockerfile is a file containing instructions to build a Docker image

Difference between links and depends_on in docker_compose.yml

According to the Docker Compose's compose-file documentation: depends_on - Express dependency between services. links - Link to containers in …

docker docker-compose dockerfile
How to copy multiple files in one layer using a Dockerfile?

The following Dockerfile contains four COPY layers: COPY README.md ./ COPY package.json ./ COPY gulpfile.js ./ COPY __BUILD_NUMBER ./ How …

dockerfile
Understanding "VOLUME" instruction in DockerFile

Below is the content of my "Dockerfile" FROM node:boron # Create app directory RUN mkdir -p /usr/src/app # change …

docker dockerfile
Connect to mysql in a docker container from the host

(It's probably a dumb question due to my limited knowledge with Docker or mysql administration, but since I spent a …

mysql docker dockerfile
Docker: How to use bash with an Alpine based docker image?

I created a docker image from openjdk:8-jdk-alpine but when I try to execute simple commands I get the following …

bash docker dockerfile alpine
How to correctly link php-fpm and Nginx Docker containers?

I am trying to link 2 separate containers: nginx:latest php:fpm The problem is that php scripts do not work. …

php nginx docker dockerfile docker-compose
How do I make a comment in a Dockerfile?

I am writing a Dockerfile. Is there a way to make comments in this file? Does Docker have a comment …

docker dockerfile
Dockerfile if else condition with external arguments

I have dockerfile FROM centos:7 ENV foo=42 then I build it docker build -t my_docker . and run it. docker …

docker dockerfile
How to define a variable in a Dockerfile?

In my Dockerfile, I would like to define variables that I can use later in the Dockerfile. I am aware …

variables docker dockerfile
How to copy file from host to container using Dockerfile

I have written a Dockerfile which looks like this FROM ubuntu:12.04 RUN apt-get update RUN apt-get install -y wget Now …

docker boot2docker dockerfile docker-registry