0.2.11 • Published 2 years ago
ms-localization v0.2.11
Localization microservice
Starting the service locally
- Make sure there is a
env-filesdirectory on the same level as this directory
- The
env-filesdirectory should contain files with env variables for all services
- Create a
.envfile in the root of the project and add all environment variables
- Some of the services have a package
@vertt/assert-env-configinstalled. If used, the functionassertEnvConfig(config)from the package checks whether all env variables are initialized. If this condition is not met, it throws an error and the service is unreachable. TheassertEnvConfig(config)function is called in theindex.tsfile. If you want to start the service without initializing all env variables, just remove this function from the code. - Mandatory environment variables are:
PORT- To initialize a unique portdatabaseUrl- To setup a connection to the databaseheaderTokenMicroservice- To be able to communicate with other servicesnpmToken- To log in to npm with the private user who is owner of the privatevertt
- Run the
init-npm-tokenscript
- This would authorize your local machine to access Vertt's private NPM repository and you would be able to install the private
@vertt/*packages - Verify the NPM access by running
npm install
- Start the service with
npm run start-local