1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-22 17:33:23 +01:00

Adding option to update lavamoat policies in parallel (#14536)

Co-authored-by: brad-decker <bhdecker84@gmail.com>
This commit is contained in:
ryanml 2022-08-09 09:08:34 -07:00 committed by GitHub
parent 06450a4056
commit 67a7483754
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 3 deletions

View File

@ -4,9 +4,16 @@ set -e
set -u
set -o pipefail
extraArgs=()
if [[ $# -lt 1 ]]; then
extraArgs+=(-m 1)
fi
# Generate LavaMoat policies for the extension background script for each build
# type.
# ATTN: This may tax your device when running it locally.
WRITE_AUTO_POLICY=1 yarn build scripts:prod --policy-only &&
WRITE_AUTO_POLICY=1 yarn build scripts:prod --policy-only --build-type beta &&
WRITE_AUTO_POLICY=1 yarn build scripts:prod --policy-only --build-type flask
concurrently --kill-others-on-fail -n main,beta,flask \
"${extraArgs[@]}" \
"WRITE_AUTO_POLICY=1 yarn build scripts:prod --policy-only" \
"WRITE_AUTO_POLICY=1 yarn build scripts:prod --policy-only --build-type beta" \
"WRITE_AUTO_POLICY=1 yarn build scripts:prod --policy-only --build-type flask"

View File

@ -73,6 +73,7 @@
"lavamoat:build:auto": "yarn lavamoat:build --writeAutoPolicy",
"lavamoat:debug:build": "yarn lavamoat:build --writeAutoPolicyDebug --policydebug lavamoat/build-system/policy-debug.json",
"lavamoat:background:auto": "./development/generate-lavamoat-policies.sh",
"lavamoat:background:auto:dev": "./development/generate-lavamoat-policies.sh --dev",
"lavamoat:auto": "yarn lavamoat:build:auto && yarn lavamoat:background:auto"
},
"resolutions": {