Last active
November 2, 2019 18:15
-
-
Save kriscoleman/e3257b73e3def64ccf77d4d1e2797bde to your computer and use it in GitHub Desktop.
My Portable Docker IDE
This file contains 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
#!/bin/sh | |
PROJECT_NAME=${PWD#"${PWD%/*/*}/"} | |
CONTAINER_NAME=${PROJECT_NAME//\//_} | |
docker run -it --rm \ | |
-v $PWD:/workspace \ | |
-v /var/run/docker.sock:/var/run/docker.sock \ | |
-v ~/.ssh:/home/me/.ssh \ | |
-v ~/.tmux/ressurect/${PROJECT_NAME}:/home/me/.tmux/resurrect \ | |
-e HOST_PATH=$PWD \ | |
-e HOST_USER_ID=$(id -u $USER) \ | |
-e HOST_GROUP_ID=$(id -g $USER) \ | |
-e PROJECT_NAME=$PROJECT_NAME \ | |
-e GIT_USER_NAME="Kris Coleman" \ | |
-e GIT_USER_EMAIL="me@email.com" \ | |
--name $CONTAINER_NAME \ | |
kriscoleman/ides:latest |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment