소스 검색

updating readme and run scripts

Signed-off-by: Logan Ballard <loganballard@gmail.com>
Logan Ballard 3 년 전
부모
커밋
69fb2a05a2
2개의 변경된 파일9개의 추가작업 그리고 8개의 파일을 삭제
  1. 7 6
      ui/README.md
  2. 2 2
      ui/package.json

+ 7 - 6
ui/README.md

@@ -23,26 +23,27 @@ kubectl port-forward --namespace opencost service/opencost 9090
 
 
 ## Running Locally
 ## Running Locally
 
 
-The UI can be run locally using the `npm run` command.
+The UI can be run locally using the `npm run serve` command.
 
 
 ```sh
 ```sh
 $ npm run serve
 $ npm run serve
 > kubecost-ui-open@0.0.1 serve
 > kubecost-ui-open@0.0.1 serve
-> BASE_URL=${BASE_URL:=/model} npx parcel serve src/index.html
+> npx parcel serve src/index.html
 
 
 Server running at http://localhost:1234
 Server running at http://localhost:1234
-✨ Built in 76ms
+✨ Built in 1.96s
 ```
 ```
 
 
 And can have a custom URL backend prefix.
 And can have a custom URL backend prefix.
 
 
 ```sh
 ```sh
-$ BASE_URL=test npm run serve
+BASE_URL=http://localhost:9090/test npm run serve
+
 > kubecost-ui-open@0.0.1 serve
 > kubecost-ui-open@0.0.1 serve
-> BASE_URL=${BASE_URL:=/model} npx parcel serve src/index.html
+> npx parcel serve src/index.html
 
 
 Server running at http://localhost:1234
 Server running at http://localhost:1234
-✨ Built in 804ms
+✨ Built in 772ms
 ```
 ```
 
 
 In addition, similar behavior can be replicated with the docker container:
 In addition, similar behavior can be replicated with the docker container:

+ 2 - 2
ui/package.json

@@ -3,8 +3,8 @@
   "version": "0.0.1",
   "version": "0.0.1",
   "description": "Open source UI for Kubecost",
   "description": "Open source UI for Kubecost",
   "scripts": {
   "scripts": {
-    "build": "BASE_URL=${BASE_URL:=/model} npx parcel build src/index.html && echo \"built with BASE_URL $BASE_URL\"",
-    "serve": "BASE_URL=${BASE_URL:=/model} npx parcel serve src/index.html",
+    "build": "npx parcel build src/index.html",
+    "serve": "npx parcel serve src/index.html",
     "clean": "rm -rf dist/*",
     "clean": "rm -rf dist/*",
     "test": "echo \"Error: no test specified\" && exit 1",
     "test": "echo \"Error: no test specified\" && exit 1",
     "preinstall": "npx npm-force-resolutions"
     "preinstall": "npx npm-force-resolutions"