From 445906a0e6a93c5a880c1469c6f8ddf9670993c4 Mon Sep 17 00:00:00 2001 From: "Shibani Basava (from Dev Box)" Date: Wed, 25 Oct 2023 06:22:07 +0000 Subject: [PATCH] ensure playwright browsers are installed in devcontainer --- .devcontainer/devcontainer.json | 2 +- .devcontainer/postCreateCommand.sh | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100755 .devcontainer/postCreateCommand.sh diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 680d76f8..3d068995 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -43,7 +43,7 @@ "forwardPorts": [3000, 3001, 5173], // Use 'postCreateCommand' to run commands after the container is created. - "postCreateCommand": "npm install", + "postCreateCommand": "./.devcontainer/postCreateCommand.sh", // Set minimal host requirements for the container. "hostRequirements": { diff --git a/.devcontainer/postCreateCommand.sh b/.devcontainer/postCreateCommand.sh new file mode 100755 index 00000000..6a1cd73c --- /dev/null +++ b/.devcontainer/postCreateCommand.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +echo "Installing dependencies..." +npm install + +echo "Installing playwright browsers..." +npx playwright install --with-deps \ No newline at end of file