Skip to content

Commit

Permalink
Work around experimental-policy issue in latest NodeJS
Browse files Browse the repository at this point in the history
  • Loading branch information
davidje13 committed Oct 28, 2023
1 parent 1bf0306 commit 03c5c5b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ jobs:
run: |
set -e;
npm install --omit=dev;
NODE_OPTIONS='--experimental-policy=./policy.json' \
./index.js > output.log 2>&1 & APP_PID="$!";
while ! grep 'Available at' < output.log > /dev/null 2>&1; do
Expand Down
2 changes: 1 addition & 1 deletion scripts/e2e.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@ if [[ -z "$TARGET_HOST" ]]; then
export $("$BASEDIR/scripts/random-secrets.js" | tee /dev/stderr | xargs);

# TODO replace express with something else to be able to add --disallow-code-generation-from-strings
# TODO once https://github.com/nodejs/node/issues/50452 is resolved, add NODE_OPTIONS='--experimental-policy="'"$BUILDDIR/policy.json"'"'
PORT="$PORT" \
MOCK_SSO_PORT="$MOCK_SSO_PORT" \
SERVER_BIND_ADDRESS="localhost" \
DB_URL="memory://refacto?simulatedLatency=50" \
NODE_OPTIONS='--experimental-policy="'"$BUILDDIR/policy.json"'"' \
node \
--disable-proto throw \
"$BUILDDIR/index.js" \
Expand Down

0 comments on commit 03c5c5b

Please sign in to comment.