Added stats group to cypher node

This commit is contained in:
SKP
2019-03-23 14:01:57 +01:00
committed by kexkey
parent b11c932cf3
commit 8b2136e1ef

View File

@@ -20,6 +20,9 @@ const clear = '\u001Bc';
const configFileVersion='0.1.0';
const defaultAPIProperties = `
# Stats can:
action_getblockchaininfo=stats
# Watcher can:
action_watch=watcher
action_unwatch=watcher
@@ -279,20 +282,26 @@ module.exports = class extends Generator {
let configEntries = [];
let clientInformation = [];
apikey.setId('000');
apikey.setGroups(['stats']);
await apikey.randomiseKey();
configEntries.push(apikey.getConfigEntry());
clientInformation.push(apikey.getClientInformation());
apikey.setId('001');
apikey.setGroups(['watcher']);
apikey.setGroups(['stats','watcher']);
await apikey.randomiseKey();
configEntries.push(apikey.getConfigEntry());
clientInformation.push(apikey.getClientInformation());
apikey.setId('002');
apikey.setGroups(['watcher','spender']);
apikey.setGroups(['stats','watcher','spender']);
await apikey.randomiseKey();
configEntries.push(apikey.getConfigEntry());
clientInformation.push(apikey.getClientInformation());
apikey.setId('003');
apikey.setGroups(['watcher','spender','admin']);
apikey.setGroups(['stats','watcher','spender','admin']);
await apikey.randomiseKey();
configEntries.push(apikey.getConfigEntry());
clientInformation.push(apikey.getClientInformation());