Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Feature multiple nodes support #245

Closed
wants to merge 10 commits into from
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# The distinction between config is as follows

## Full

Node, Faucet, and Monitor are running on the same computer.

## Standard

Node and Monitor are running and no Faucet on the same computer.

## Light

Only Explorer or Portal running on the computer.
Original file line number Diff line number Diff line change
@@ -1,76 +1,251 @@
const config = {
restURL: `${location.protocol}//${location.hostname}:1317`,
websocketURL: `${location.protocol.replace('http', 'ws')}//${location.hostname}:26657`,
chainID: 'ununifi-8-private-test',
bech32Prefix: {
accAddr: 'ununifi',
accPub: 'ununifipub',
valAddr: 'ununifivaloper',
valPub: 'ununifivaloperpub',
consAddr: 'ununifivalcons',
consPub: 'ununifivalconspub',
},
minimumGasPrices: [
{
denom: 'uguu',
amount: 0.015,
const configs = [
// local
{
id: location.hostname,
restURL: `${location.protocol}//${location.hostname}:1317`,
websocketURL: `${location.protocol.replace('http', 'ws')}//${location.hostname}:26657`,
chainID: 'ununifi-8-private-test',
bech32Prefix: {
accAddr: 'ununifi',
accPub: 'ununifipub',
valAddr: 'ununifivaloper',
valPub: 'ununifivaloperpub',
consAddr: 'ununifivalcons',
consPub: 'ununifivalconspub',
},
],
extension: {
faucet: [
{
hasFaucet: true,
faucetURL: `${location.protocol}//${location.hostname}:8000`,
denom: 'ubtc',
creditAmount: 100, // amount to credit in max request
maxCredit: 99, // account has already maxCredit balance cannot claim anymore
},
minimumGasPrices: [
{
hasFaucet: true,
faucetURL: `${location.protocol}//${location.hostname}:8002`,
denom: 'uguu',
creditAmount: 2000000,
maxCredit: 1999999,
},
{
hasFaucet: false,
faucetURL: `${location.protocol}//${location.hostname}:8004`,
denom: 'jpu',
creditAmount: 10,
maxCredit: 9,
amount: 0.015,
},
],
monitor: {
monitorURL: `${location.protocol}//${location.hostname}:9000`,
extension: {
faucet: [
{
hasFaucet: true,
faucetURL: `${location.protocol}//${node}:8000`,
denom: 'ubtc',
creditAmount: 100, // amount to credit in max request
maxCredit: 99, // account has already maxCredit balance cannot claim anymore
},
{
hasFaucet: true,
faucetURL: `${location.protocol}//${node}:8002`,
denom: 'uguu',
creditAmount: 2000000,
maxCredit: 1999999,
},
{
hasFaucet: false,
faucetURL: `${location.protocol}//${node}:8004`,
denom: 'jpu',
creditAmount: 10,
maxCredit: 9,
},
{
hasFaucet: true,
faucetURL: `${location.protocol}//${node}:8006`,
denom: 'ueth',
creditAmount: 1000,
maxCredit: 999,
},
{
hasFaucet: false,
faucetURL: `${location.protocol}//${node}:8008`,
denom: 'euu',
creditAmount: 10,
maxCredit: 9,
},
],
monitor: {
monitorURL: `${location.protocol}//${location.hostname}:9000`,
},
navigations: [],
messageModules: [
'bank',
'auth',
'crisis',
'distribution',
'evidence',
'genaccounts',
'gov',
'ibc',
'slashing',
'staking',
'auction',
'ununifidist',
'cdp',
'incentive',
'pricefeed',
],
},
},
// A node
{
id: 'a.private-test.ununifi.cauchye.net',
restURL: `${location.protocol}//a.private-test.ununifi.cauchye.net:1317`,
websocketURL: `${location.protocol.replace(
'http',
'ws',
)}//a.private-test.ununifi.cauchye.net:26657`,
chainID: 'ununifi-8-private-test',
bech32Prefix: {
accAddr: 'ununifi',
accPub: 'ununifipub',
valAddr: 'ununifivaloper',
valPub: 'ununifivaloperpub',
consAddr: 'ununifivalcons',
consPub: 'ununifivalconspub',
},
navigations: [
minimumGasPrices: [
{
name: 'Monitor',
link: '/monitor',
icon: 'monitor',
denom: 'uguu',
amount: 0.015,
},
],
extension: {
faucet: [
{
hasFaucet: true,
faucetURL: `${location.protocol}//a.private-test.ununifi.cauchye.net:8000`,
denom: 'ubtc',
creditAmount: 100, // amount to credit in max request
maxCredit: 99, // account has already maxCredit balance cannot claim anymore
},
{
hasFaucet: true,
faucetURL: `${location.protocol}//a.private-test.ununifi.cauchye.net:8002`,
denom: 'uguu',
creditAmount: 2000000,
maxCredit: 1999999,
},
{
hasFaucet: false,
faucetURL: `${location.protocol}//a.private-test.ununifi.cauchye.net:8004`,
denom: 'jpu',
creditAmount: 10,
maxCredit: 9,
},
{
hasFaucet: true,
faucetURL: `${location.protocol}//a.private-test.ununifi.cauchye.net:8006`,
denom: 'ueth',
creditAmount: 1000,
maxCredit: 999,
},
{
hasFaucet: false,
faucetURL: `${location.protocol}//a.private-test.ununifi.cauchye.net:8008`,
denom: 'euu',
creditAmount: 10,
maxCredit: 9,
},
],
monitor: {
monitorURL: `${location.protocol}//${location.hostname}:9000`,
},
navigations: [],
messageModules: [
'bank',
'auth',
'crisis',
'distribution',
'evidence',
'genaccounts',
'gov',
'ibc',
'slashing',
'staking',
'auction',
'ununifidist',
'cdp',
'incentive',
'pricefeed',
],
},
},
// B node
{
id: 'b.private-test.ununifi.cauchye.net',
restURL: `${location.protocol}//b.private-test.ununifi.cauchye.net:1317`,
websocketURL: `${location.protocol.replace(
'http',
'ws',
)}//b.private-test.ununifi.cauchye.net:26657`,
chainID: 'ununifi-8-private-test',
bech32Prefix: {
accAddr: 'ununifi',
accPub: 'ununifipub',
valAddr: 'ununifivaloper',
valPub: 'ununifivaloperpub',
consAddr: 'ununifivalcons',
consPub: 'ununifivalconspub',
},
minimumGasPrices: [
{
name: 'UnUniFi',
link: '/ununifi/',
icon: 'toll',
denom: 'uguu',
amount: 0.015,
},
],
messageModules: [
'bank',
'auth',
'crisis',
'distribution',
'evidence',
'genaccounts',
'gov',
'ibc',
'slashing',
'staking',
'auction',
'ununifidist',
'cdp',
'incentive',
'pricefeed',
],
extension: {
faucet: [
{
hasFaucet: true,
faucetURL: `${location.protocol}//b.private-test.ununifi.cauchye.net:8000`,
denom: 'ubtc',
creditAmount: 100, // amount to credit in max request
maxCredit: 99, // account has already maxCredit balance cannot claim anymore
},
{
hasFaucet: true,
faucetURL: `${location.protocol}//b.private-test.ununifi.cauchye.net:8002`,
denom: 'uguu',
creditAmount: 2000000,
maxCredit: 1999999,
},
{
hasFaucet: false,
faucetURL: `${location.protocol}//b.private-test.ununifi.cauchye.net:8004`,
denom: 'jpu',
creditAmount: 10,
maxCredit: 9,
},
{
hasFaucet: true,
faucetURL: `${location.protocol}//b.private-test.ununifi.cauchye.net:8006`,
denom: 'ueth',
creditAmount: 1000,
maxCredit: 999,
},
{
hasFaucet: false,
faucetURL: `${location.protocol}//b.private-test.ununifi.cauchye.net:8008`,
denom: 'euu',
creditAmount: 10,
maxCredit: 9,
},
],
monitor: {
monitorURL: `${location.protocol}//b.private-test.ununifi.cauchye.net:9000`,
},
navigations: [],
messageModules: [
'bank',
'auth',
'crisis',
'distribution',
'evidence',
'genaccounts',
'gov',
'ibc',
'slashing',
'staking',
'auction',
'ununifidist',
'cdp',
'incentive',
'pricefeed',
],
},
},
};
];
Loading