Merge branch 'develop' into t3chguy/add-webpack-sentry-workaround

This commit is contained in:
Michael Telatynski 2024-01-22 14:51:53 +00:00 committed by GitHub
commit 0aed37a2e5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 39 additions and 16 deletions

View file

@ -8,14 +8,8 @@ const MiniCssExtractPlugin = require("mini-css-extract-plugin");
const TerserPlugin = require("terser-webpack-plugin");
const CssMinimizerPlugin = require("css-minimizer-webpack-plugin");
const HtmlWebpackInjectPreload = require("@principalstudio/html-webpack-inject-preload");
const crypto = require("crypto");
const CopyWebpackPlugin = require("copy-webpack-plugin");
// XXX: mangle Crypto::createHash to replace md4 with sha256, output.hashFunction is insufficient as multiple bits
// of webpack hardcode md4. The proper fix it to upgrade to webpack 5.
const createHash = crypto.createHash;
crypto.createHash = (algorithm, options) => createHash(algorithm === "md4" ? "sha256" : algorithm, options);
// Environment variables
// RIOT_OG_IMAGE_URL: specifies the URL to the image which should be used for the opengraph logo.
// CSP_EXTRA_SOURCE: specifies a URL which should be appended to each CSP directive which uses 'self',