This page intends to git hints on how to use Docker for packaging.

See for an example of the Dockerfile used to generate a build environment for the package itself.

See for a more classical approach to the problem by sharing directories between the host and packaging containers.

#Install the docker service

 $apt-get install

#Create Debian Sid docker container 

 $docker run -it --rm --name deb-sid debian:sid /bin/bash 

#Note: Give different name in --name option for creating new containers  

#Install the required packages in the container

 $apt-get install dh-make gem2deb npm2deb

#Press Ctl + p + q to exit from the container without stopping it.

# For accessing back the container 

 $ docker ps 

#Find the container ID and attach it to the current bash terminal using the following commands

 $docker attach <Container ID>  

$ sudo docker ps
CONTAINER ID        IMAGE               COMMAND             CREATED             STATUS              PORTS               NAMES
0cf9a333ad8b        debian:sid          "/bin/bash"         28 minutes ago      Up 2 minutes                            jolly

$docker attach 0cf9a333ad8b


CategoryVirtualization | CategoryPackaging