Skip to content

Commit

Permalink
move devnet rpc node to rpc terraform and start to tag by sha
Browse files Browse the repository at this point in the history
  • Loading branch information
Liam Lai committed Mar 18, 2024
1 parent 7c6f802 commit 974e364
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 11 deletions.
6 changes: 3 additions & 3 deletions cicd/devnet/terraform/s3.tf
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# Bucket need to be created first. If first time run terraform init, need to comment out the below section
terraform {
backend "s3" {
bucket = "tf-devnet-bucket" // This name need to be updated to be the same as local.s3BucketName. We can't use variable here.
key = "tf/terraform_new.tfstate"
bucket = "tf-xinfin-bucket" // This name need to be updated to be the same as local.s3BucketName. We can't use variable here.
key = "tf/terraform_devnet.tfstate"
region = "us-east-1"
encrypt = true
}
}

data "aws_s3_object" "devnet_xdc_node_config" {
bucket = local.s3BucketName
bucket = "tf-xinfin-bucket"
key = "node-config.json"
}
4 changes: 0 additions & 4 deletions cicd/devnet/terraform/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,4 @@ locals {
for r in local.regions :
r.name => { for i in local.keyNames[r.name]: i => local.predefinedNodesConfig[i] }
}

rpcNodeKeys = { "rpc1": local.predefinedNodesConfig["rpc1"]} // we hardcode the rpc to a single node for now

s3BucketName = "tf-devnet-bucket"
}
6 changes: 3 additions & 3 deletions cicd/terraform/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ module "devnet-rpc" {
logLevel = local.logLevel
xdc_ecs_tasks_execution_role_arn = aws_iam_role.xdc_ecs_tasks_execution_role.arn

cpu = 2048
cpu = 1024
memory = 4096

network = "devnet"
Expand All @@ -46,7 +46,7 @@ module "testnet-rpc" {
logLevel = local.logLevel
xdc_ecs_tasks_execution_role_arn = aws_iam_role.xdc_ecs_tasks_execution_role.arn

cpu = 2048
cpu = 1024
memory = 4096

network = "testnet"
Expand All @@ -65,7 +65,7 @@ module "mainnet-rpc" {
logLevel = local.logLevel
xdc_ecs_tasks_execution_role_arn = aws_iam_role.xdc_ecs_tasks_execution_role.arn

cpu = 2048
cpu = 1024
memory = 4096

network = "mainnet"
Expand Down
2 changes: 1 addition & 1 deletion cicd/terraform/s3.tf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
terraform {
backend "s3" {
bucket = "tf-xinfin-bucket"
key = "tf/terraform.tfstate"
key = "tf/terraform_rpc.tfstate"
region = "us-east-1"
encrypt = true
}
Expand Down

0 comments on commit 974e364

Please sign in to comment.