blob: e796dc7ebc3395ef3f360ccb22bb742a8a5c60a2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
# Example instructions from https://docs.docker.com/reference/builder/
FROM ubuntu:14.04
MAINTAINER example@example.com
ENV foo /bar
WORKDIR ${foo} # WORKDIR /bar
ADD . $foo # ADD . /bar
COPY \$foo /quux # COPY $foo /quux
RUN apt-get update && apt-get install -y software-properties-common\
zsh curl wget git htop\
unzip vim telnet
RUN ["/bin/bash", "-c", "echo hello ${USER}"]
CMD ["executable","param1","param2"]
CMD command param1 param2
EXPOSE 1337
ENV myName="John Doe" myDog=Rex\ The\ Dog \
myCat=fluffy
ENV myName John Doe
ENV myDog Rex The Dog
ENV myCat fluffy
ADD hom* /mydir/ # adds all files starting with "hom"
ADD hom?.txt /mydir/ # ? is replaced with any single character
COPY hom* /mydir/ # adds all files starting with "hom"
COPY hom?.txt /mydir/ # ? is replaced with any single character
ENTRYPOINT ["executable", "param1", "param2"]
ENTRYPOINT command param1 param2
VOLUME ["/data"]
USER daemon
LABEL com.example.label-with-value="foo"
LABEL version="1.0"
LABEL description="This text illustrates \
that label-values can span multiple lines."
WORKDIR /path/to/workdir
ONBUILD ADD . /app/src
|