mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Replaced selected docs references to ADD with COPY
Docker-DCO-1.1-Signed-off-by: James Turnbull <james@lovedthanlost.net> (github: jamtur01)
This commit is contained in:
parent
31f0cc04ec
commit
a1ddf57216
4 changed files with 6 additions and 6 deletions
|
@ -52,7 +52,7 @@ which you can `docker pull`. You can then use that
|
|||
image to base your new minimal containers `FROM`:
|
||||
|
||||
FROM scratch
|
||||
ADD true-asm /true
|
||||
COPY true-asm /true
|
||||
CMD ["/true"]
|
||||
|
||||
The Dockerfile above is from extremely minimal image - [tianon/true](
|
||||
|
|
|
@ -52,7 +52,7 @@ Now let's add a configuration file for Supervisor. The default file is
|
|||
called `supervisord.conf` and is located in
|
||||
`/etc/supervisor/conf.d/`.
|
||||
|
||||
ADD supervisord.conf /etc/supervisor/conf.d/supervisord.conf
|
||||
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
|
||||
|
||||
Let's see what is inside our `supervisord.conf`
|
||||
file.
|
||||
|
|
|
@ -84,11 +84,11 @@ via-package-manager#rhelcentosscientific-linux-6):
|
|||
# Install Node.js and npm
|
||||
RUN yum install -y npm
|
||||
|
||||
To bundle your app's source code inside the Docker image, use the `ADD`
|
||||
To bundle your app's source code inside the Docker image, use the `COPY`
|
||||
instruction:
|
||||
|
||||
# Bundle app source
|
||||
ADD . /src
|
||||
COPY . /src
|
||||
|
||||
Install your app dependencies using the `npm` binary:
|
||||
|
||||
|
@ -117,7 +117,7 @@ Your `Dockerfile` should now look like this:
|
|||
RUN yum install -y npm
|
||||
|
||||
# Bundle app source
|
||||
ADD . /src
|
||||
COPY . /src
|
||||
# Install app dependencies
|
||||
RUN cd /src; npm install
|
||||
|
||||
|
|
|
@ -53,7 +53,7 @@ After that, we install and setup a few dependencies:
|
|||
|
||||
RUN locale-gen en_US en_US.UTF-8
|
||||
|
||||
ADD supervisord.conf /etc/supervisor/conf.d/supervisord.conf
|
||||
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
|
||||
|
||||
RUN echo 'root:basho' | chpasswd
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue