DevOps task by askcharlie
This script will check weather vagrant with version >=1.6 is installed or not. If yes, then the script will perform vagrant up operation.
If the vagrant command from setup.sh will complete successfully, one can check the status of nginx and redis container. eg. curl -L http://192.168.100.101:80 should show nginx welcome page.
below command will help in initializing redis from file data.txt
-
vagrant scp data.txt :/home/vagrant e.g. vagrant scp data.txt c261fa6:/home/vagrant
-
docker ps | grep redis | awk '{print $1}'
-
docker cp data.txt :/data/data.txt
-
docker exec sh -c 'cat /data/data.txt | redis-cli --pipe'