based on disease and painlevel hospital lists are suggested
Steps:
- Download repo and go to project folder
- npm init
- npm install nodemon
- Run
nodemon server.js
- Go to browser and enter http://localhost:7000
Steps using docker:
- cd to sql service folder:
docker build -t test-mysql .
docker run -d \
--publish 6603:3306 \
--volume=/Users/afrida/Documents/Course/paloit/sqlservice/data:/var/lib/mysql \
--name=testmysqlservice test-mysql
mysql -u root -p -h localhost -P 6603 -D patientschem
- Now, for nodejs docker, in terminal type
cd ..
to comeback on project directory docker build -t test-nodejs .
docker run -d \
--publish 7000:7000 \
-e MYSQL_USER='root' \
-e MYSQL_PASSWORD='password' \
-e MYSQL_DATABASE='patientschem' \
-e MYSQL_HOST='172.17.0.2' \
--link testmysqlservice:db \
--name=test-nodejs-service test-nodejs
- From host machine terminal type command:
curl localhost:7000
- Will show port listening on 7000