Notice that virtualbox version should be < 4.3.13
- Create a new file as your working directory for vagrant. Make sure you have all priviledges accessing to this directory.
- Clone all the files in this directory.
- CMD
- Run:
- $ vagrant up --provision --no-parallel
- You will see "Thank you for using nginx.", meaning it has been successfully setup.
- Check the status of docker containers you just created:
- $ vagrant global-status
- Use third-party tool such as Putty to SSH into Host VM
- Look up the docker container:
- $ docker ps - Enter the specific docker container:
- $ docker exec -it (Container ID) /bin/bash
- Still use Putty to SSH into container because the port forwarding has been introduced.
Note that SQL is not actually installed since I have not decided which SQL I will use. Thus it is just a normal sript validating the connection between two containers. And Vagrant itself should have supported the ansible provisioning directly without shell provisioning. However, the latest version of ansible contains some bugs that cause Vagrantfile cannot check the existance of ansible installed in containers.