Skip to content

Commit

Permalink
[tf] set default num_validators_in_genesis same as num_validators
Browse files Browse the repository at this point in the history
Closes: diem#3141
Approved by: mgorven
  • Loading branch information
sherry-x authored and bors-libra committed Mar 26, 2020
1 parent 80b8894 commit 5ad239b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion terraform/validators.tf
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ data "template_file" "ecs_task_definition" {
cfg_listen_addr = var.validator_use_public_ip == true ? element(aws_instance.validator.*.public_ip, count.index) : element(aws_instance.validator.*.private_ip, count.index)
cfg_node_index = count.index
cfg_num_validators = var.cfg_num_validators_override == 0 ? var.num_validators : var.cfg_num_validators_override
cfg_num_validators_in_genesis = var.num_validators_in_genesis
cfg_num_validators_in_genesis = var.num_validators_in_genesis == 0? var.num_validators : var.num_validators_in_genesis
cfg_seed = var.config_seed
cfg_seed_peer_ip = local.seed_peer_ip

Expand Down
4 changes: 2 additions & 2 deletions terraform/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ variable "num_validators" {
}

variable "num_validators_in_genesis" {
default = 4
description = "Number of validator nodes to include in genesis blob"
default = 0
description = "Number of validator nodes to include in genesis blob, 0 will default to using num_validators"
}

# This allows you to use a override number of validators for config generation
Expand Down

0 comments on commit 5ad239b

Please sign in to comment.