Docker build and run

Code examples

20
0

docker build

docker build -t [tag] .
3
0

docker run command on container

sudo docker exec -it <container name> <command>
3
0

docker build -t

--tag , -t   ---->   Name and optionally a tag in the ‘name:tag’ format
1
0

dockerfile example

FROM ubuntu:18.04
COPY . /app
RUN make /app
CMD python /app/app.py
1
0

docker ARG

$ docker build --build-arg some_variable_name=a_value
1
0

how to create docker image from custom filename

cat DockerFile.debian.foo | docker build -t debian.foo -

In other languages

This page is in other languages

Русский
..................................................................................................................
Italiano
..................................................................................................................
Polski
..................................................................................................................
Română
..................................................................................................................
한국어
..................................................................................................................
हिन्दी
..................................................................................................................
Français
..................................................................................................................
Türk
..................................................................................................................
Česk
..................................................................................................................
Português
..................................................................................................................
ไทย
..................................................................................................................
中文
..................................................................................................................
Español
..................................................................................................................
Slovenský
..................................................................................................................
Балгарскі
..................................................................................................................
Íslensk
..................................................................................................................