Skip to content

Instantly share code, notes, and snippets.

@dbcesar
Last active January 12, 2018 22:24
Show Gist options
  • Save dbcesar/e3d14e6aa519e4950de0c708185da3e7 to your computer and use it in GitHub Desktop.
Save dbcesar/e3d14e6aa519e4950de0c708185da3e7 to your computer and use it in GitHub Desktop.
sudo apt-get install docker.io
%%%%%%%%%%%%%%%%%%%%%%%%%
% Run with ubuntu:16:04
docker run --rm -ti ubuntu:16.04 /bin/bash
%%%%%%%%%%%%%%%%%%%%%%%%%
% commit changes
sudo su
docker ps
% get the container name and then commit
docker commit [CONTAINER_NAME] [DESTINY_CONTAINER]
%check changes with
docker images
%%%%%%%%%%%%%%%%%%%%%%%%
docker run --rm -ti -v /home/diego/docker_rock/:/home/diego/docker -ti pre_rock /bin/bash
docker run --rm -ti -v [destiny_folder]:[folder_inside_image] -ti [image name] /bin/bash
%%%%%%%%%%%%%%%%%%%%%%%%
Create additional bash
get the container name via `docker ps -a` and run, for the case it is caller "nostalgic_morse"
`docker exec -it nostalgic_morse bash`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment