Skip to content

Commit

Permalink
chore: clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
RiceAndMeet committed Apr 29, 2024
1 parent efda680 commit 0513206
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 7 deletions.
1 change: 0 additions & 1 deletion .github/workflows/build-latest-docker-image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ on:
push:
branches:
- main
- feat/dockerize-build
workflow_dispatch:
jobs:
build-and-push-latest-docker-image:
Expand Down
4 changes: 2 additions & 2 deletions terraform/mainnet/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ resource "aws_iam_role" "lambda_role" {
resource "aws_lambda_function" "function" {
function_name = "${var.package_name}-${var.environment}"
package_type = "Image"
image_uri = "499786161782.dkr.ecr.us-east-2.amazonaws.com/axelarscan-api:v${var.app_version}"
image_uri = "${var.aws_account}.dkr.ecr.us-east-2.amazonaws.com/axelarscan-api:v${var.app_version}"
role = aws_iam_role.lambda_role.arn
timeout = 840
memory_size = 512
Expand All @@ -106,7 +106,7 @@ resource "aws_lambda_function" "function" {
LOG_LEVEL = var.log_level
DD_LAMBDA_HANDLER = "index.handler"
DD_SITE = "datadoghq.com"
DD_API_KEY_SECRET_ARN = "arn:aws:secretsmanager:us-east-2:499786161782:secret:DdApiKeySecret-gJ9EIYVknJGu-HYZ3nM"
DD_API_KEY_SECRET_ARN = "arn:aws:secretsmanager:us-east-2:${var.aws_account}:secret:DdApiKeySecret-gJ9EIYVknJGu-HYZ3nM"
DD_TRACE_ENABLED = true
DD_ENV = var.environment
DD_SERVICE = "${var.package_name}-${var.environment}"
Expand Down
5 changes: 5 additions & 0 deletions terraform/mainnet/variables.tf.example
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ variable "aws_region" {
default = "us-east-2"
}

variable "aws_account" {
description = "AWS account id"
default = ""
}

variable "iam_role" {
description = "AWS IAM role"
default = "axelar-gmp-role-lambda"
Expand Down
4 changes: 2 additions & 2 deletions terraform/stagenet/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ resource "aws_iam_role" "lambda_role" {
resource "aws_lambda_function" "function" {
function_name = "${var.package_name}-${var.environment}"
package_type = "Image"
image_uri = "499786161782.dkr.ecr.us-east-2.amazonaws.com/axelarscan-api:v${var.app_version}"
image_uri = "${var.aws_account}.dkr.ecr.us-east-2.amazonaws.com/axelarscan-api:v${var.app_version}"
role = aws_iam_role.lambda_role.arn
timeout = 30
memory_size = 512
Expand All @@ -106,7 +106,7 @@ resource "aws_lambda_function" "function" {
LOG_LEVEL = var.log_level
DD_LAMBDA_HANDLER = "index.handler"
DD_SITE = "datadoghq.com"
DD_API_KEY_SECRET_ARN = "arn:aws:secretsmanager:us-east-2:499786161782:secret:DdApiKeySecret-gJ9EIYVknJGu-HYZ3nM"
DD_API_KEY_SECRET_ARN = "arn:aws:secretsmanager:us-east-2:${var.aws_account}:secret:DdApiKeySecret-gJ9EIYVknJGu-HYZ3nM"
DD_TRACE_ENABLED = true
DD_ENV = var.environment
DD_SERVICE = "${var.package_name}-${var.environment}"
Expand Down
5 changes: 5 additions & 0 deletions terraform/stagenet/variables.tf.example
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ variable "aws_region" {
default = "us-east-2"
}

variable "aws_account" {
description = "AWS account id"
default = ""
}

variable "iam_role" {
description = "AWS IAM role"
default = "axelar-gmp-role-lambda"
Expand Down
4 changes: 2 additions & 2 deletions terraform/testnet/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ resource "aws_iam_role" "lambda_role" {
resource "aws_lambda_function" "function" {
function_name = "${var.package_name}-${var.environment}"
package_type = "Image"
image_uri = "499786161782.dkr.ecr.us-east-2.amazonaws.com/axelarscan-api:v${var.app_version}"
image_uri = "${var.aws_account}.dkr.ecr.us-east-2.amazonaws.com/axelarscan-api:v${var.app_version}"
role = aws_iam_role.lambda_role.arn
timeout = 30
memory_size = 512
Expand All @@ -106,7 +106,7 @@ resource "aws_lambda_function" "function" {
LOG_LEVEL = var.log_level
DD_LAMBDA_HANDLER = "index.handler"
DD_SITE = "datadoghq.com"
DD_API_KEY_SECRET_ARN = "arn:aws:secretsmanager:us-east-2:499786161782:secret:DdApiKeySecret-gJ9EIYVknJGu-HYZ3nM"
DD_API_KEY_SECRET_ARN = "arn:aws:secretsmanager:us-east-2:${var.aws_account}:secret:DdApiKeySecret-gJ9EIYVknJGu-HYZ3nM"
DD_TRACE_ENABLED = true
DD_ENV = var.environment
DD_SERVICE = "${var.package_name}-${var.environment}"
Expand Down
5 changes: 5 additions & 0 deletions terraform/testnet/variables.tf.example
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ variable "aws_region" {
default = "us-east-2"
}

variable "aws_account" {
description = "AWS account id"
default = ""
}

variable "iam_role" {
description = "AWS IAM role"
default = "axelar-gmp-role-lambda"
Expand Down

0 comments on commit 0513206

Please sign in to comment.