Created
June 15, 2017 00:47
-
-
Save summerwind/ec2788d22f03cbf70e5f821996b65228 to your computer and use it in GitHub Desktop.
python command wrapper for Container Linux
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 | |
if [ "${CONTAINER}" = "1" ]; then | |
/usr/local/bin/python $@ | |
else | |
docker run \ | |
-it --rm \ | |
-v /:/host \ | |
-v /opt:/opt \ | |
-v /home:/home \ | |
-e CONTAINER=1 \ | |
python:2.7.13-alpine python $@ | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment