This is backend module of secret_tech ICO dashboard: https://demo.icodashboard.space.
It was implemented to provide following functionality:
docker-compose build --no-cache
.docker-compose up -d
.cp .env.test .env
.docker-compose exec ico yarn
.docker-compose exec ico yarn test
.npm install -g aglio
.mkdir /usr/local/lib/node_modules/aglio/node_modules/aglio-theme-olio/cache
.aglio --theme-variables cyborg --theme-template triple -i apiary.apib -o ./docs/index.html
..env
. For a basis it is possible to take .env.stage
or .env.prod
.docker-compose build --no-cache
Run the services docker-compose up -d
Note: The auth and verify services should be accessible from the outside. More in detail with the configuration of these services can be found in their readme.
Install dependencies and build the project docker-compose exec ico npm i && docker-compose exec ico npm run build
Generate a token for a tenant:
curl --include \
--request POST \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data-binary "{
\"email\": \"test@test.com\",
\"password\": \"Password1\"
}" \
'http://auth:3000/tenant'
curl --include \
--request POST \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data-binary "{
\"email\": \"test@test.com\",
\"password\": \"Password1\"
}" \
'http://auth:3000/tenant/login'
Note: If you start it in ico service, you must install
curl
. This can be done with theapk add curl
command.
Specify the received token in .env
AUTH_JWT
.
Copy the certificates to the dist/certs
directory.
Rename or delete the src
directory.
Note: If the test environment is deployed and
.env.test
is used, files fromsrc
will be used.
Run ico service:
npm run serve
Note: If the dev environment, will run
npm run start
command.