npm install
npm start
There are currently 2 configurations:
- config.js: for preprod
- config.prod.js: for prod
A configuration file is like this:
const path = require('path');
module.exports = {
target: 'https://preprodpromise12apiapp.azurewebsites.net/',
cert: path.resolve(__dirname, '../certs/Promise12.pfx')
};
target
: the remote url to proxy request to.cert
: the path to the certificate pfx thing.
ENV
: the default mode proxies request to the preprod environment. UseENV=production
to call the prod one.PASSPHRASE
: if needed, the passphrase related to the pfx file.PORT
: the port for the proxy (default: 9000).TOKEN
: the token to identify client. You must pass a header namedtoken
with the matching value !