mirror of
https://github.com/kubeshark/kubeshark.git
synced 2025-07-17 09:51:56 +00:00
Mizu start dev commands (#726)
* start dev commands * env files * no message
This commit is contained in:
parent
4be7164f20
commit
2e5cf13b3f
3
ui/.env.dev.basic
Normal file
3
ui/.env.dev.basic
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
REACT_APP_OVERRIDE_WS_URL="ws://localhost:8899/ws"
|
||||||
|
REACT_APP_OVERRIDE_API_URL="http://localhost:8899/"
|
||||||
|
REACT_APP_OVERRIDE_IS_ENTERPRISE="false"
|
3
ui/.env.dev.enterprise
Normal file
3
ui/.env.dev.enterprise
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
REACT_APP_OVERRIDE_WS_URL="ws://localhost:8899/ws"
|
||||||
|
REACT_APP_OVERRIDE_API_URL="http://localhost:8899/"
|
||||||
|
REACT_APP_OVERRIDE_IS_ENTERPRISE="true"
|
@ -49,7 +49,8 @@
|
|||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "craco start",
|
"start": "craco start",
|
||||||
"start-ent": "./node_modules/.bin/env-cmd -f .env.enterprise craco start",
|
"start-dev": "./node_modules/.bin/env-cmd -f .env.dev.basic craco start",
|
||||||
|
"start-dev-ent": "./node_modules/.bin/env-cmd -f .env.dev.enterprise craco start",
|
||||||
"build": "./node_modules/.bin/env-cmd -f .env.basic craco build",
|
"build": "./node_modules/.bin/env-cmd -f .env.basic craco build",
|
||||||
"build-ent": "BUILD_PATH='./build-ent' ./node_modules/.bin/env-cmd -f .env.enterprise craco build",
|
"build-ent": "BUILD_PATH='./build-ent' ./node_modules/.bin/env-cmd -f .env.enterprise craco build",
|
||||||
"test": "craco test",
|
"test": "craco test",
|
||||||
|
@ -1,12 +1,13 @@
|
|||||||
import * as axios from "axios";
|
import * as axios from "axios";
|
||||||
|
|
||||||
export const MizuWebsocketURL = window.location.protocol === 'https:' ? `wss://${window.location.host}/ws` : `ws://${window.location.host}/ws`;
|
export const MizuWebsocketURL = process.env.REACT_APP_OVERRIDE_WS_URL ? process.env.REACT_APP_OVERRIDE_WS_URL :
|
||||||
|
window.location.protocol === 'https:' ? `wss://${window.location.host}/ws` : `ws://${window.location.host}/ws`;
|
||||||
|
|
||||||
export const FormValidationErrorType = "formError";
|
export const FormValidationErrorType = "formError";
|
||||||
|
|
||||||
const CancelToken = axios.CancelToken;
|
const CancelToken = axios.CancelToken;
|
||||||
|
|
||||||
const apiURL =`${window.location.origin}/`;
|
const apiURL = process.env.REACT_APP_OVERRIDE_API_URL ? process.env.REACT_APP_OVERRIDE_API_URL : `${window.location.origin}/`;
|
||||||
|
|
||||||
export default class Api {
|
export default class Api {
|
||||||
static instance;
|
static instance;
|
||||||
|
Loading…
Reference in New Issue
Block a user