- Make sure you have
node
andnpm
installed - Run
npm install
to install the dependencies - Run
npm run dev
to start the server - Head to
localhost:3000
Configuration added on Dockerfile
.
- Build Docker image:
docker build -t us.gcr.io/sudokux-186808/sudokux .
. Confirm build by checking if image is listeddocker images
. - Run the container
docker run -d --name sudoku -p 3000:3000 us.gcr.io/sudokux-186808/sudokux
- Access the app on http://0.0.0.0:3000
This app is hosted on gcloud
following instructions found on GCP docs(https://cloud.google.com/kubernetes-engine/docs/tutorials/hello-app) or on this medium post(https://medium.com/@delanhype/dockerizing-and-deploying-a-nodejs-app-7779b1a2d2f6)