Commit a5881dbe authored by Cédric Moreau's avatar Cédric Moreau

[enh] allow to force enabling/disabling WS2P sync

parent c2253019
......@@ -85,6 +85,7 @@ export interface WS2PConfDTO {
ws2p?: {
privateAccess?: boolean
publicAccess?: boolean
sync?: boolean
uuid?: string
upnp?: boolean
remotehost?: string|null
......
......@@ -41,6 +41,8 @@ export const WS2PDependency = {
{ value: '--ws2p-public', desc: 'Enable WS2P Public access.' },
{ value: '--ws2p-noprivate', desc: 'Disable WS2P Private access.' },
{ value: '--ws2p-nopublic', desc: 'Disable WS2P Public access.' },
{ value: '--ws2p-sync', desc: 'Enable WS2P SYNC access.' },
{ value: '--ws2p-nosync', desc: 'Disable WS2P SYNC access.' },
{ value: '--ws2p-prefered-add <pubkey>', desc: 'Add a prefered node to connect to through private access.' },
{ value: '--ws2p-prefered-rm <pubkey>', desc: 'Remove prefered node.' },
{ value: '--ws2p-prefered-only <pubkey>', desc: 'Only connect to prefered node.' },
......@@ -79,6 +81,8 @@ export const WS2PDependency = {
if (program.ws2pPublic !== undefined) conf.ws2p.publicAccess = true
if (program.ws2pNoprivate !== undefined) conf.ws2p.privateAccess = false
if (program.ws2pNopublic !== undefined) conf.ws2p.publicAccess = false
if (program.ws2pSync !== undefined) conf.ws2p.sync = true
if (program.ws2pNosync !== undefined) conf.ws2p.sync = false
// Prefered nodes
if (program.ws2pPreferedAdd !== undefined) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment