diff --git a/cmd/mycelo/templates.go b/cmd/mycelo/templates.go index bcd7cfa9fb..632b03523e 100644 --- a/cmd/mycelo/templates.go +++ b/cmd/mycelo/templates.go @@ -4,6 +4,7 @@ import ( "math/big" "math/rand" + "github.com/celo-org/celo-blockchain/common" "github.com/celo-org/celo-blockchain/common/decimal/fixed" "github.com/celo-org/celo-blockchain/mycelo/env" "github.com/celo-org/celo-blockchain/mycelo/genesis" @@ -115,7 +116,7 @@ func (e monorepoEnv) createEnv(workdir string) (*env.Environment, error) { Accounts: env.AccountsConfig{ Mnemonic: env.MustNewMnemonic(), NumValidators: 3, - ValidatorsPerGroup: 1, + ValidatorsPerGroup: 5, // monorepo uses a single validator group, max group size is 5 NumDeveloperAccounts: 0, UseValidatorAsAdmin: true, // monorepo doesn't use the admin account type, uses first validator instead }, @@ -137,6 +138,11 @@ func (e monorepoEnv) createGenesisConfig(env *env.Environment) (*genesis.Config, BlockPeriod: 1, RequestTimeout: 3000, }) + // To match the 'testing' config in monorepo + genesisConfig.EpochRewards.TargetVotingYieldInitial = fixed.MustNew("0.00016") + genesisConfig.EpochRewards.TargetVotingYieldMax = fixed.MustNew("0.0005") + genesisConfig.EpochRewards.TargetVotingYieldAdjustmentFactor = fixed.MustNew("0.1") + genesisConfig.Reserve.InitialBalance = common.MustBigInt("100000000000000000000000000") // 100M CELO // Add balances to validator accounts instead of developer accounts genesis.FundAccounts(genesisConfig, env.Accounts().ValidatorAccounts()) diff --git a/mycelo/genesis/base_config.go b/mycelo/genesis/base_config.go index e4348e8d1a..7dec511903 100644 --- a/mycelo/genesis/base_config.go +++ b/mycelo/genesis/base_config.go @@ -147,7 +147,7 @@ func BaseConfig() *Config { DowntimeSlasher: DowntimeSlasherParameters{ Reward: bigIntStr("10000000000000000000"), // 10 cGLD Penalty: bigIntStr("100000000000000000000"), // 100 cGLD - SlashableDowntime: 60, // Should be overridden on public testnets + SlashableDowntime: 4, // make it small so it works with small epoch sizes, e.g. 10 }, Governance: GovernanceParameters{ UseMultiSig: true,