Skip to content

Commit

Permalink
uncomment lines to demo different outputs of CMD and ENTRYPOINT
Browse files Browse the repository at this point in the history
  • Loading branch information
shadjac committed Jan 16, 2019
1 parent 019966f commit 778043f
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions CMDVsEntrypointDemoDockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
FROM nginx:latest
RUN apt-get update && apt-get install vim telnet -y
# DEMO 1
#ENTRYPOINT ["/bin/echo", "Hello"]
#CMD ["world"]
# DEMO 2
#ENTRYPOINT ["/bin/echo", "Hello"]
#CMD ["world"]
# DEMO 3
#ENV name sheldon
#ENTRYPOINT ["/bin/bash", "-c", "echo Hello, $name"]
#ENTRYPOINT ["/bin/echo", "Hello $name"]
#ENTRYPOINT echo hello $name
# DEMO 4
ENTRYPOINT echo Hello
CMD ["world"]

0 comments on commit 778043f

Please sign in to comment.