Browse Source

Updated dependencies and instructions for building

Signed-off-by: Matt Ray <github@mattray.dev>
Signed-off-by: Thomas Evans <tevans3@icloud.com>
Matt Ray 2 năm trước cách đây
mục cha
commit
7c046a3ebb
3 tập tin đã thay đổi với 936 bổ sung837 xóa
  1. 7 5
      ui/README.md
  2. 928 832
      ui/package-lock.json
  3. 1 0
      ui/package.json

+ 7 - 5
ui/README.md

@@ -26,8 +26,10 @@ kubectl port-forward --namespace opencost service/opencost 9090
 The UI can be run locally using the `npm run serve` command.
 
 ```sh
+$ npm install
+...
 $ npm run serve
-> kubecost-ui-open@0.0.1 serve
+> opencost-ui@0.1.0 serve
 > npx parcel serve src/index.html
 
 Server running at http://localhost:1234
@@ -39,7 +41,7 @@ And can have a custom URL backend prefix.
 ```sh
 BASE_URL=http://localhost:9090/test npm run serve
 
-> kubecost-ui-open@0.0.1 serve
+> opencost-ui@0.1.0 serve
 > npx parcel serve src/index.html
 
 Server running at http://localhost:1234
@@ -51,13 +53,13 @@ In addition, similar behavior can be replicated with the docker container:
 ```sh
 $ docker run -e BASE_URL_OVERRIDE=test -p 9091:9090 -d opencost-ui:latest
 $ curl localhost:9091
-<html gibberish> 
+<html gibberish>
 ```
 
 ## Overriding the Base API URL
 
-For some use cases such as the case of [Opencost deployed behind an ingress controller](https://github.com/opencost/opencost/issues/1677), it is useful to override the `BASE_URL` variable responsible for requests sent from the UI to the API.  This means that instead of sending requests to `<domain>/model/allocation/compute/etc`, requests can be sent to `<domain>/{BASE_URL_OVERRIDE}/allocation/compute/etc`.  To do this, supply the environment variable `BASE_URL_OVERRIDE` to the docker image.
+For some use cases such as the case of [OpenCost deployed behind an ingress controller](https://github.com/opencost/opencost/issues/1677), it is useful to override the `BASE_URL` variable responsible for requests sent from the UI to the API.  This means that instead of sending requests to `<domain>/model/allocation/compute/etc`, requests can be sent to `<domain>/{BASE_URL_OVERRIDE}/allocation/compute/etc`.  To do this, supply the environment variable `BASE_URL_OVERRIDE` to the docker image.
 
 ```sh
 $ docker run -p 9091:9090 -e BASE_URL_OVERRIDE=anything -d opencost-ui:latest
-```
+```

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 928 - 832
ui/package-lock.json


+ 1 - 0
ui/package.json

@@ -36,6 +36,7 @@
     "@babel/plugin-transform-runtime": "^7.13.10",
     "@babel/preset-react": "^7.12.13",
     "parcel": "^2.2.1",
+    "process": "^0.11.10",
     "set-value": "4.0.1"
   },
   "resolutions": {

Một số tệp đã không được hiển thị bởi vì quá nhiều tập tin thay đổi trong này khác