Sandbox environment to stand up a MEAN app with Docker.
- API: business logic layer
- DB: persistence layer
- Web: public website
- Admin: administration website
cd app-api
npm install
docker build --no-cache -t meanapp-api:latest .
docker run -d --rm -p 3000:3000 --env PORT=3000 --env NODE_ENV=production --env VIRTUAL_HOST=app-api.docker.local meanapp-api:latest
cd ..
cd app-web
npm install
docker build --no-cache -t meanapp-web:latest .
docker run -d --rm -p 8100:8100 --env PORT=8100 --env NODE_ENV=production --env VIRTUAL_HOST=app-web.docker.local meanapp-web:latest
cd ..
Connect to the REST API: http://127.0.0.1:3000
Connect to the public website: http://127.0.0.1:3100
- GET / - Gets the hello world message.
- GET /continents - Gets a list of continents.
- GET /continents?sort=alpha - Gets a list of all continents sorted alphabetically.
- GET /continents?sort=pop - Gets a list of all continents sorted by largest population.
- GET /continents/:continentName - Gets the specified content by name.