fix(fix3): runtime env hardening and public endpoint source-of-truth
This commit is contained in:
@@ -21,7 +21,8 @@ function takeValue(args: string[], index: number, flag: string): string {
|
||||
function parseInstallOptions(args: string[]): InstallOptions {
|
||||
const options: InstallOptions = {
|
||||
packageDir: "",
|
||||
configPath: "/etc/hy2xs/hy2xs.env",
|
||||
sourceConfigPath: "",
|
||||
runtimeConfigPath: "/etc/hy2xs/hy2xs.env",
|
||||
nonInteractive: false,
|
||||
skipFirewall: false,
|
||||
skipStart: false
|
||||
@@ -44,7 +45,7 @@ function parseInstallOptions(args: string[]): InstallOptions {
|
||||
options.skipStart = true;
|
||||
break;
|
||||
case "--config":
|
||||
options.configPath = takeValue(args, i, arg);
|
||||
options.sourceConfigPath = takeValue(args, i, arg);
|
||||
i += 1;
|
||||
break;
|
||||
default:
|
||||
@@ -64,7 +65,8 @@ function parseInstallOptions(args: string[]): InstallOptions {
|
||||
function parseReconfigureOptions(args: string[]): ReconfigureOptions {
|
||||
const options: ReconfigureOptions = {
|
||||
packageDir: "",
|
||||
configPath: "/etc/hy2xs/hy2xs.env",
|
||||
sourceConfigPath: "/etc/hy2xs/hy2xs.env",
|
||||
runtimeConfigPath: "/etc/hy2xs/hy2xs.env",
|
||||
nonInteractive: false,
|
||||
dryRun: false,
|
||||
apply: false,
|
||||
@@ -80,7 +82,7 @@ function parseReconfigureOptions(args: string[]): ReconfigureOptions {
|
||||
i += 1;
|
||||
break;
|
||||
case "--config":
|
||||
options.configPath = takeValue(args, i, arg);
|
||||
options.sourceConfigPath = takeValue(args, i, arg);
|
||||
i += 1;
|
||||
break;
|
||||
case "--dry-run":
|
||||
|
||||
Reference in New Issue
Block a user