Update API backend URLs from ngrok to seekright production server
This commit is contained in:
@@ -7,12 +7,12 @@ import psutil
|
|||||||
CLIENT_ID = "client_1"
|
CLIENT_ID = "client_1"
|
||||||
|
|
||||||
import os
|
import os
|
||||||
# Using the public ngrok URL so the agent can connect from anywhere in the world!
|
# Using the central production backend URL
|
||||||
CENTRAL_API_URL = f"https://culprit-campfire-galore.ngrok-free.dev/api/get-command?client_id={CLIENT_ID}"
|
CENTRAL_API_URL = f"http://rmm-backend.seekright.com/api/get-command?client_id={CLIENT_ID}"
|
||||||
CENTRAL_TELEMETRY_URL = f"https://culprit-campfire-galore.ngrok-free.dev/api/telemetry?client_id={CLIENT_ID}"
|
CENTRAL_TELEMETRY_URL = f"http://rmm-backend.seekright.com/api/telemetry?client_id={CLIENT_ID}"
|
||||||
|
|
||||||
platform_name = "nt" if os.name == "nt" else "posix"
|
platform_name = "nt" if os.name == "nt" else "posix"
|
||||||
CENTRAL_COMMANDS_URL = f"https://culprit-campfire-galore.ngrok-free.dev/api/get-commands?platform={platform_name}"
|
CENTRAL_COMMANDS_URL = f"http://rmm-backend.seekright.com/api/get-commands?platform={platform_name}"
|
||||||
|
|
||||||
# SECURITY MECHANISM: The "Whitelist"
|
# SECURITY MECHANISM: The "Whitelist"
|
||||||
# The agent NEVER executes arbitrary strings from the internet.
|
# The agent NEVER executes arbitrary strings from the internet.
|
||||||
|
|||||||
@@ -46,11 +46,11 @@ import os
|
|||||||
|
|
||||||
CLIENT_ID = "TEMPLATE_CLIENT_ID"
|
CLIENT_ID = "TEMPLATE_CLIENT_ID"
|
||||||
|
|
||||||
CENTRAL_API_URL = f"https://culprit-campfire-galore.ngrok-free.dev/api/get-command?client_id={CLIENT_ID}"
|
CENTRAL_API_URL = f"http://rmm-backend.seekright.com/api/get-command?client_id={CLIENT_ID}"
|
||||||
CENTRAL_TELEMETRY_URL = f"https://culprit-campfire-galore.ngrok-free.dev/api/telemetry?client_id={CLIENT_ID}"
|
CENTRAL_TELEMETRY_URL = f"http://rmm-backend.seekright.com/api/telemetry?client_id={CLIENT_ID}"
|
||||||
|
|
||||||
platform_name = "nt" if os.name == "nt" else "posix"
|
platform_name = "nt" if os.name == "nt" else "posix"
|
||||||
CENTRAL_COMMANDS_URL = f"https://culprit-campfire-galore.ngrok-free.dev/api/get-commands?platform={platform_name}"
|
CENTRAL_COMMANDS_URL = f"http://rmm-backend.seekright.com/api/get-commands?platform={platform_name}"
|
||||||
|
|
||||||
CACHED_COMMANDS = {}
|
CACHED_COMMANDS = {}
|
||||||
|
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ scrape_configs:
|
|||||||
# - job_name: "desktop_ngrok_test"
|
# - job_name: "desktop_ngrok_test"
|
||||||
# scheme: https
|
# scheme: https
|
||||||
# static_configs:
|
# static_configs:
|
||||||
# - targets: ["culprit-campfire-galore.ngrok-free.dev"]
|
# - targets: ["rmm-backend.seekright.com"]
|
||||||
#
|
#
|
||||||
# - job_name: "sasi_gpu"
|
# - job_name: "sasi_gpu"
|
||||||
# scheme: https
|
# scheme: https
|
||||||
|
|||||||
@@ -15,17 +15,11 @@ import {
|
|||||||
Play
|
Play
|
||||||
} from 'lucide-react';
|
} from 'lucide-react';
|
||||||
|
|
||||||
const API_BASE = 'https://culprit-campfire-galore.ngrok-free.dev'; // Target FastAPI central server in production VM
|
const API_BASE = 'http://rmm-backend.seekright.com'; // Target FastAPI central server in production VM
|
||||||
|
|
||||||
// Secure API fetch wrapper to automatically bypass ngrok's transitional browser warning page
|
// Secure API fetch wrapper
|
||||||
const apiFetch = (url, options = {}) => {
|
const apiFetch = (url, options = {}) => {
|
||||||
return fetch(url, {
|
return fetch(url, options);
|
||||||
...options,
|
|
||||||
headers: {
|
|
||||||
...options.headers,
|
|
||||||
'ngrok-skip-browser-warning': 'true'
|
|
||||||
}
|
|
||||||
});
|
|
||||||
};
|
};
|
||||||
|
|
||||||
function App() {
|
function App() {
|
||||||
|
|||||||
@@ -5,7 +5,8 @@ import react from '@vitejs/plugin-react'
|
|||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
plugins: [react()],
|
plugins: [react()],
|
||||||
server: {
|
server: {
|
||||||
host: 'localhost',
|
host: '0.0.0.0',
|
||||||
port: 8080,
|
port: 4173,
|
||||||
|
allowedHosts: ["rmm.seekright.com"]
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
Reference in New Issue
Block a user