This document outlines the steps involved in deploying the orchestrator, which is built with Webpack.
Prerequisites:
Clone the repo at masivapp-orchestrator - Repos (visualstudio.com)
Install dependencies
npm install
Use the build script from the package.json
package.json file depending on the desired environment (labs, test or prod)
# For labs
npm run build:labs
# For test
npm run build:test
# For prod
npm run build:prod
index_csp.html
file in your project's build directory and open it in a browser.Inspect the browser's developer console or network tab to identify the hashes generated for the static resources (e.g., scripts, stylesheets, images).
Collect these hashes and note them down. (e.g. ‘sha256-hJbVqSaMjbweHWEBD8PtyXgtuSlasFH5vTUyQxRhlK0=’
)
CSP hashes are different depending on the deployment environment. While the CSP policy in labs is **report-only,** let’s just focus on prod environment.
⚠️ It’s important to update the policy in both resources because Cloudfront function handles white label frontend and lambda edge handles frontend.masivapp.com access.
It’s mandatory to update the CSP policy in the following resources. Here’s the step by step: