Pre-requisites:
- Docker must be installed on your system(For Windows/MacOs - VM+docker(from official site))
HOW TO USE:
- sudo su
- git pull the repo in some folder
- To run App in container
- docker-compose run (development service will start in container, volume setup will be done). 2. 2.1 docker build -t ashuimage -f Dockerfile.dev . 2.2 docker run ashuimage (for dev server) 2.3 docker run ashuimage npm run test (for testing server)
- 1.1 docker build -t ashuimage1 . 1.2 docker run ashuimage (production running on nginx)
- Setup Travis Account
- Get this repo on travis
- Push code on github - travis will fetch and start running tests (.travis.yml)
==> Remember to :
- not select linux2(it will auto start docker-compose rather than Dockerfile), choose linux.
- make a new user (goto IAM -> select users) -> give previledge to "ElasticBeanStalkAllAccess" -> Copy access_id and secret_id -> paste it to environment of Travis(it will enject it inside our program here (looks for $xxx))
- Remember to expose port -nginx in Dockerfile ! - Already done : )
Change development branch and then create a pull request once it runs great !