Introduction to Docker
Introduction to Docker
Jihar Al Gifari
What is Docker?
Docker is a tool designed to make
it easier to create, deploy, and run
applications by using containers.
Containers allow a developer to
package up an application with all
of the parts it needs, such as
libraries and other dependencies,
and ship it all out as one package
M
u
lt
ip
l
ic
it
y
o
f
G
o
o
d
s
M
u
l
t
i
p
il
ic
it
y
o
f
m
e
t
h
o
d
s
f
o
r
t
r
a
n
s
p
o
r
t
in
g
/
s
t
o
r
in
g
D
o
I
w
o
r
r
y
a
b
o
u
t
h
o
w
g
o
o
d
s
i
n
t
e
r
a
c
t
(
e
.
g
.
c
o
f
f
e
e
b
e
a
n
s
n
e
x
t
t
o
s
p
ic
e
s
)
C
a
n
I
t
r
a
n
s
p
o
r
t
q
u
ic
k
l
y
a
n
d
s
m
o
o
t
h
ly
(
e
.
g
.
f
r
o
m
b
o
a
t
t
o
t
r
a
in
t
o
t
r
u
c
k
)
Cargo Transport Pre-1960
Static website
Web frontend
Background workers
User DB
Analytics DB
Queue
Developmen
t VM
QA ServerSingle Prod
Server
Onsite
Cluster
Public CloudContributor’
s laptop
Customer
Servers
Docker eliminates the matrix from Hell
Docker CLI
• docker build # Build an image from a Dockerfile
• docker images # List all images on a Docker host
• docker run # Run an image
• docker ps # List all running and stopped instances
• docker stop # Stop a running instances
• docker rm # Remove an instance
• docker rmi # Remove an image
How to install Docker
●uname -r.
●sudo apt-get update
●sudo apt-get install apt-transport-https ca-certificates
●sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80
--recv-keys 58118E89F3A912897C070ADBF76221572C52609D
●sudo nano /etc/apt/sources.list.d/docker.list
tambahkan
deb https://apt.dockerproject.org/repo ubuntu-xenial main