Skip to content

Instantly share code, notes, and snippets.

@Qaaj

Qaaj/commands.sh

Created Nov 28, 2017
Embed
What would you like to do?
// Tag and custom dockerfile
docker build -t cryptotracker . -f Dockerfile.txt
docker container prune
// ENV file
docker run -e REDIS_URL='...' --env-file vars -p 3001:3001 cryptotracker
// Networks
docker network list
docker network create <network>
docker network inspect <network>
docker network prune
// Volumes
docker volume ls
docker volume inspect <volume>
docker volume prune
//
// Tail running container
docker logs <container> -f
// Attach to running container
docker exec -it <container> bash
// MISC
docker tag oldtag newtag
// Amazon
aws ecr --no-include-email get-login
-d detached mode
/var/lib/cloud/scripts/per-boot
sudo chmod +x <script>
34.209.248.211
docker run --name testredis -p 6379:6379 --network mynetwork redis
docker run --name cryptoTracker -p 3001:3001 -e REDIS_URL=redis://testredis:6379 --network mynetwork cryptotracker
docker run --name cryptoTracker -p 3001:3001 -e REDIS_URL=redis://testredis:6379 --network mynetwork 781057470561.dkr.ecr.us-west-2.amazonaws.com/test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.