Last active
June 11, 2021 18:45
-
-
Save rachidbch/9ef6187b57b3e4c415f571d0e2991ae0 to your computer and use it in GitHub Desktop.
Docker Scripts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Docker Scripts | |
Scripts that can be executed from a command line |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl -fsSL https://get.docker.com | sh | |
sudo curl -L "https://github.com/docker/compose/releases/download/1.26.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
sudo usermod -aG docker $USER | |
newgrp docker | |
newgrp $USER | |
# Sometimes, when Docker is installed by root, but launched by user in docker group, | |
# Docker fails with a cryptic message about map segment error shared library libz.so.1 | |
# This is due to Docker trying to access root's tmp folder without permission | |
# This teaches Docker where to look for tmp folder | |
echo "export TMPDIR=$HOME/tmp" >> ~/.bashrc | |
# Then verify Install with: | |
# $ docker run hello-world |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment