Add unified port configuration system
- Unified API and WebUI on single configurable port (default: 4567) - Added strix.yaml configuration file support (go2rtc-style format) - Environment variable STRIX_API_LISTEN overrides config file - Port validation and source logging - Relative URLs in frontend for automatic port detection - Removed separate server instances - Cleaned up temporary files and updated .gitignore - Updated documentation with configuration examples
This commit is contained in:
@@ -1,9 +1,8 @@
|
||||
export class CameraSearchAPI {
|
||||
constructor(baseURL = null) {
|
||||
// Auto-detect API URL based on current host
|
||||
// Use relative URLs since API and UI are on the same port
|
||||
if (!baseURL) {
|
||||
const currentHost = window.location.hostname;
|
||||
this.baseURL = `http://${currentHost}:8080`;
|
||||
this.baseURL = '';
|
||||
} else {
|
||||
this.baseURL = baseURL;
|
||||
}
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
export class StreamDiscoveryAPI {
|
||||
constructor(baseURL = null) {
|
||||
// Auto-detect API URL based on current host
|
||||
// Use relative URLs since API and UI are on the same port
|
||||
if (!baseURL) {
|
||||
const currentHost = window.location.hostname;
|
||||
this.baseURL = `http://${currentHost}:8080`;
|
||||
this.baseURL = '';
|
||||
} else {
|
||||
this.baseURL = baseURL;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user