Skip to content

fix: pass ami_id_ssm_parameter_name to runners module#4702

Closed
zoezhangmattr wants to merge 1 commit intogithub-aws-runners:mainfrom
zoezhangmattr:fix-ami
Closed

fix: pass ami_id_ssm_parameter_name to runners module#4702
zoezhangmattr wants to merge 1 commit intogithub-aws-runners:mainfrom
zoezhangmattr:fix-ami

Conversation

@zoezhangmattr
Copy link
Copy Markdown

try to fix #4701

@zoezhangmattr zoezhangmattr requested a review from a team as a code owner August 12, 2025 03:31
@zoezhangmattr
Copy link
Copy Markdown
Author

after this change, 2 resources updated, lambda function has environment variable
policy is created for lambda

resource "aws_lambda_function" "scale_up" {
  ~ environment {
          ~ variables = {
              + "AMI_ID_SSM_PARAMETER_NAME"                = "/github-action-runners/ami/xxxxx"
...
}
resource "aws_iam_policy" "ami_id_ssm_parameter_read" {
+ policy           = jsonencode(
            {
              + Statement = [
                  + {
                      + Action   = [
                          + "ssm:GetParameter",
                        ]
                      + Effect   = "Allow"
                      + Resource = [
                          + "arn:aws:ssm:xxxxxxx:xxxxxxxx:parameter/github-action-runners/ami/xxxxx",
                        ]
                    },
                ]
              + Version   = "2012-10-17"
            }
        )
.....
}

@zoezhangmattr
Copy link
Copy Markdown
Author

to be removed, so no add bacl.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ami_id_ssm_parameter_name is not in multi-runner module

1 participant