Skip to content

Instantly share code, notes, and snippets.

@vpack
Last active June 15, 2018 15:58
Show Gist options
  • Save vpack/ae0f735a104b96763793 to your computer and use it in GitHub Desktop.
Save vpack/ae0f735a104b96763793 to your computer and use it in GitHub Desktop.
Docker Quick Install
yum -y install epel-release
yum -y install docker
systemctl enable docker
systemctl start docker
curl -L https://github.com/docker/machine/releases/download/v0.5.0/docker-machine_linux-amd64.zip >machine.zip
unzip machine.zip
rm machine.zip
mv docker-machine* /usr/local/bin
# Docker Jenkins
ssh ip-10-44-151-123.ec2.internal
docker images
git clone https://github.com/jenkinsci/docker.git
docker rmi vpack:jenkin # Remove Image
docker build -t vpack:jenkins .
vi docker-compose.yml
# Docker Compose
docker-compose build
docker-compose up -d
docker-compose run web /usr/local/bin/python create_db.py
docker-compose run web env
docker-compose logs
psql -h 192.168.99.100 -p 5432 -U postgres --password
# Docker Compose using Cloud Provider
docker-machine create -d digitalocean --digitalocean-access-token=ADD_YOUR_TOKEN_HERE production
Reference:
- https://realpython.com/blog/python/dockerizing-flask-with-compose-and-machine-from-localhost-to-the-cloud/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment