Skip to content

Commit

Permalink
(feat) Running shell with run:shell shouldn't use the CSP (#613)
Browse files Browse the repository at this point in the history
  • Loading branch information
ibacher authored Feb 21, 2023
1 parent 7bc5b3f commit 11b11ad
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions packages/shell/esm-app-shell/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const BundleAnalyzerPlugin =
const WebpackPwaManifest = require("webpack-pwa-manifest");
const { InjectManifest } = require("workbox-webpack-plugin");
const { DefinePlugin, container } = require("webpack");
const { resolve, dirname, basename } = require("path");
const { resolve } = require("path");
const { readdirSync, statSync } = require("fs");
const { removeTrailingSlash, getTimestamp } = require("./tools/helpers");
const { name, version, dependencies } = require("./package.json");
Expand All @@ -16,7 +16,6 @@ const frameworkVersion = require("@openmrs/esm-framework/package.json").version;

const timestamp = getTimestamp();
const production = "production";
const allowedSuffixes = ["-app", "-widgets"];
const { ModuleFederationPlugin } = container;

const openmrsAddCookie = process.env.OMRS_ADD_COOKIE;
Expand Down Expand Up @@ -103,6 +102,10 @@ module.exports = (env, argv = {}) => {
proxyReq.setHeader("cookie", newCookie);
}
},
onProxyRes(proxyRes) {
proxyRes.headers &&
delete proxyRes.headers["content-security-policy"];
},
},
],
},
Expand Down

0 comments on commit 11b11ad

Please sign in to comment.