All installs require an instance of mongodb available.
- MongoDB 4.0 or newer
- Docker 18.09.1 or newer
Run docker build . -t sae-workbench to build the docker container and the following commands to run it
hostip=$(ifconfig en0 | awk '$1 == "inet" {print $2}')
docker run -e LOG_LEVEL=info -e SESSION_SECRET="s3cr3t" -e SESSION_COOKIE_SECURE=true \
-e OIDC_ISSUER="https://oidc/auth/realms/myrealm" \
-e OIDC_CLIENT_ID=workbench -e OIDC_CLIENT_SECRET=s3c3rt \
-e OIDC_AUTH_URL="https://oidc/auth/realms/myrealm/protocol/openid-connect/auth" \
-e OIDC_TOKEN_URL="https://oidc/auth/realms/myrealm/protocol/openid-connect/token" \
-e OIDC_USERINFO_URL="https://oidc/auth/realms/myrealm/protocol/openid-connect/userinfo" \
-e OIDC_CALLBACK_URL="http://localhost/" \
-e OIDC_SCOPE="openid offline_access" \
--add-host=docker:$hostip -p LOCALPORT:8000 sae-workbenchThis web application uses MERN boiler plate, for additional documentation see mern.io.
npm install
npm start
-
npm run start- starts the development server with hot reloading enabled -
npm run bs- bundles the code and starts the production server -
npm run test- start the test runner -
npm run watch:test- start the test runner with watch mode -
npm run cover- generates test coverage report -
npm run lint- runs linter to check for lint errors
There are docker configurations for both development and production.
To run docker for development,
docker-compose -f docker-compose-development.yml build
docker-compose -f docker-compose-development.yml up
To run docker for production,
docker-compose build
docker-compose up