From 6df3abc19a0357cff45fbe3e3e169ee7c4c5b34f Mon Sep 17 00:00:00 2001 From: Matthias Feyll <matthias.feyll@@stud.h-da.de> Date: Wed, 8 Jan 2025 10:32:16 +0100 Subject: [PATCH] (ui): add dev env script --- react-ui/package.json | 3 ++- react-ui/scripts/dev.sh | 11 +++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100755 react-ui/scripts/dev.sh diff --git a/react-ui/package.json b/react-ui/package.json index 709c5bfcb..4c9271009 100755 --- a/react-ui/package.json +++ b/react-ui/package.json @@ -37,7 +37,8 @@ "build::api": "npx @rtk-query/codegen-openapi ./scripts/openapi-config.json", "build": "yarn build::api && yarn build::frontend", "lint": "eslint src", - "lint::fix": "eslint src --fix" + "lint::fix": "eslint src --fix", + "dev": "./scripts/dev.sh" }, "eslintConfig": { "extends": [ diff --git a/react-ui/scripts/dev.sh b/react-ui/scripts/dev.sh new file mode 100755 index 000000000..3a2d20885 --- /dev/null +++ b/react-ui/scripts/dev.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env sh + +docker run \ + -it \ + --rm \ + -v $(pwd):/app \ + -w /app \ + -p 127.0.0.1:3000:3000 \ + --network gosdn-csbi-arista-base-net \ + node:20-alpine3.20 \ + npx vite -- GitLab