I am trying to deploy an app based on angular to bluemix and I want to use system variables (process.env). Somehow this does not work and process only contains title=browser and an empty env object. I set them on the environment but I can't get the dotenv to work. The app is based on the angular-cli.
Does somebody know how to safely store api keys with or without dotenv and such?
EDIT: some code from the app.module. I also tried it in the main.ts file but to no avail.
export function restServiceLoader(logger: NGXLogger, http: HttpClient): any {
logger.debug('test is ' + process.env.TEST);
return new ApiDataService(logger, http);
}