diff --git a/src/components/SettingsModal.vue b/src/components/SettingsModal.vue
index a48ce51..3c9698d 100644
--- a/src/components/SettingsModal.vue
+++ b/src/components/SettingsModal.vue
@@ -56,6 +56,13 @@
+
@@ -126,6 +133,7 @@ export default {
apiPassword: '',
dataPath: '',
hostPort: '',
+ siaMuxPort: '',
rpcPort: '',
notice: null,
errors: {},
@@ -146,6 +154,11 @@ export default {
hasErrors = true;
}
+ if (this.siaMuxPort && this.siaMuxPort.length > 0 && portRegex.exec(this.siaMuxPort) === null) {
+ errors['siaMuxPort'] = 'SiaMux port must match the format :9983';
+ hasErrors = true;
+ }
+
if (this.rpcPort && this.rpcPort.length > 0 && portRegex.exec(this.rpcPort) === null) {
errors['rpcPort'] = 'RPC port must match the format :9981';
hasErrors = true;
@@ -166,6 +179,7 @@ export default {
this.apiAgent = this.config.siad_api_agent;
this.apiPassword = this.config.siad_api_password;
this.dataPath = this.config.siad_data_path;
+ this.siaMuxPort = this.config.siad_siamux_port;
this.hostPort = this.config.siad_host_port;
this.rpcPort = this.config.siad_rpc_port;
},
@@ -179,6 +193,7 @@ export default {
siad_api_agent: this.apiAgent,
siad_api_password: this.apiPassword,
siad_data_path: this.dataPath,
+ siad_siamux_port: this.siaMuxPort,
siad_host_port: this.hostPort,
siad_rpc_port: this.rpcPort
};
@@ -252,6 +267,17 @@ export default {
if (this.changed)
this.notice = 'Changes will not take effect until daemon restart.';
},
+ siaMuxPort(val) {
+ this.validate();
+
+ if (this.changed)
+ return;
+
+ this.changed = (val !== this.config.siad_siamux_port);
+
+ if (this.changed)
+ this.notice = 'Changes will not take effect until daemon restart.';
+ },
hostPort(val) {
this.validate();
diff --git a/src/sia/daemon.js b/src/sia/daemon.js
index f4b411d..6e7e86d 100644
--- a/src/sia/daemon.js
+++ b/src/sia/daemon.js
@@ -17,6 +17,9 @@ function buildArgs(config) {
if (typeof config.siad_host_port === 'string' && config.siad_host_port.length > 0)
args.push('--host-addr', config.siad_host_port);
+ if (typeof config.siad_siamux_port === 'string' && config.siad_siamux_port.length > 0)
+ args.push('--siamux-addr', config.siad_siamux_port);
+
if (typeof config.siad_rpc_port === 'string' && config.siad_rpc_port.length > 0)
args.push('--rpc-addr', config.siad_rpc_port);
diff --git a/src/views/setup/DaemonOverrideStep.vue b/src/views/setup/DaemonOverrideStep.vue
index c3c1cb6..f887723 100755
--- a/src/views/setup/DaemonOverrideStep.vue
+++ b/src/views/setup/DaemonOverrideStep.vue
@@ -7,6 +7,10 @@
Do you want to change any Daemon flags?
Some hosts use custom ports or change their API authentication. Change any of the daemon settings you need to. Leave blank to use the default value.
+
+
+
+
@@ -47,6 +51,7 @@ export default {
mounted() {
this.userAgent = this.config.siad_api_agent;
this.hostPort = this.config.siad_host_port;
+ this.siaMuxPort = this.config.siad_siamux_port;
this.rpcPort = this.config.siad_rpc_port;
this.apiAddr = this.config.siad_api_addr;
},
@@ -54,6 +59,7 @@ export default {
return {
userAgent: null,
hostPort: null,
+ siaMuxPort: null,
rpcPort: null,
apiAddr: null,
apiPassword: null
@@ -66,6 +72,7 @@ export default {
config: {
'siad_api_agent': this.userAgent,
'siad_host_port': this.hostPort,
+ 'siad_siamux_port': this.siaMuxPort,
'siad_rpc_port': this.rpcPort,
'siad_api_addr': this.apiAddr,
'siad_api_password': this.apiPassword