Removed web project (galvanic authentication support in IL2CPP universal patch)

Moved instance ID to header
User instances for profile management
.. other stuff
This commit is contained in:
2025-03-22 21:57:45 -04:00
parent 73e9b72ad4
commit 6cdd0946f4
42 changed files with 663 additions and 3833 deletions

View File

@@ -14,19 +14,22 @@ type RedisConfiguration = {
type WebConfiguration = {
port: number,
host: string,
nameserverHost: string,
secureNameserverHost: boolean
publichost: string,
securepublichost: boolean
}
type PublicConfiguration = {
serverName: string,
serverId: string,
owner: string,
motd: string,
levelScale: number,
maxLevels: number
patches: string[],
}
type LoggingConfiguration = {
notfound: boolean,
debug: boolean,
network: boolean
}
@@ -37,13 +40,12 @@ type DiscordConfiguration = {
guildId: string
}
type SecretConfiguration = {
authSecret: string
}
type RecaptchaConfiguration = {
sitekey: string,
secret: string
type AuthConfiguration = {
secret: string,
/**
* In Hours
*/
timeout: number
}
export type GalvanicConfiguration = {
@@ -52,8 +54,7 @@ export type GalvanicConfiguration = {
public: PublicConfiguration,
logging: LoggingConfiguration,
discord: DiscordConfiguration | null,
secrets: SecretConfiguration,
recaptcha: RecaptchaConfiguration | null
auth: AuthConfiguration
}
export const defaultConfig: GalvanicConfiguration = {
@@ -67,29 +68,32 @@ export const defaultConfig: GalvanicConfiguration = {
web: {
port: 3000,
host: "127.0.0.1",
nameserverHost: "127.0.0.1:3000",
secureNameserverHost: false
publichost: "127.0.0.1:3000",
securepublichost: false,
},
public: {
serverName: "Galvanic Corrosion",
serverId: "galvanic-corrosion-default",
owner: "John Doe",
motd: "The narwhal bacons at midnight",
motd: "A Galvanic Corrosion server.",
levelScale: 1,
maxLevels: 30
maxLevels: 30,
patches: [],
},
logging: {
notfound: false,
debug: false,
network: false
},
discord: null,
secrets: {
authSecret: "CHANGE-ME-PLEASE"
},
recaptcha: null
auth: {
secret: "CHANGE-ME-PLEASE",
timeout: 48
}
}
/** The current configuration. Read and parsed only during startup. */
let config: GalvanicConfiguration | undefined;
let config: GalvanicConfiguration;
try {
if (!configurationExists()) generateDefaultConfig();
config = JSON.parse(fs.readFileSync('./config.json').toString());
@@ -113,4 +117,6 @@ export function getConfig() {
return config;
}
export const devMode = Deno.args.includes('--dev');
export * as Config from './config.ts';