//// package.json for development windows
"clean:server": "if exist ./dist-server rmdir /q /s dist-server",
"clean:client": "if exist ./dist-client rmdir /q /s dist-client",

//// create and run a postgres docker instance map docker port 5432 to external port= 15432, name= opa-local password= hatio
docker run -p 15432:5432 --name opa-local -e  POSTGRES_PASSWORD=hatio -d postgres

//// remove all docker images. It will NOT remove those images that are being used.
docker rmi $(docker images -a -q)

//// build app into docker image
docker image build -t operato/pms:${VERSION} .

//// run image as container mapped port 3000 internally to 4000 externally
docker run -p 4000:3000 operato/pms:1

//// export docker image as tar file to be copied to another server
docker save -o docker_operato_nginx.tar 3fd59fc2d41a


$ yarn install

$ yarn build # build all packages

$ DEBUG=things-factory:*,typeorm:* yarn workspace @things-factory/operato-pms run migration

$ DEBUG=things-factory:* yarn workspace @things-factory/operato-pms run serve:dev

$ yarn workspace @things-factory/operato-pms build

//// build docker image
$ yarn workspace @things-factory/operato-pms run docker

//// run docker image
$ yarn workspace @things-factory/operato-pms run docker:run

//// run docker-compose in background
docker-compose up -d