mirror of
https://github.com/stashapp/stash.git
synced 2025-12-18 12:54:38 +03:00
Configuration
* Added flags to customize the host and port * Start up just one server rather than a server for HTTP and HTTPS. HTTPS server will only start if a cert and key are found
This commit is contained in:
@@ -8,7 +8,13 @@ export class StashService {
|
||||
|
||||
public static initialize() {
|
||||
const platformUrl = new URL(window.location.origin);
|
||||
platformUrl.port = platformUrl.protocol === "https:" ? "9999" : "9998";
|
||||
if (!process.env.NODE_ENV || process.env.NODE_ENV === "development") {
|
||||
platformUrl.port = "9999"; // TODO: Hack. Development expects port 9999
|
||||
|
||||
if (process.env.REACT_APP_HTTPS === "true") {
|
||||
platformUrl.protocol = "https:";
|
||||
}
|
||||
}
|
||||
const url = platformUrl.toString().slice(0, -1);
|
||||
|
||||
StashService.client = new ApolloClient({
|
||||
|
||||
Reference in New Issue
Block a user