Skip to content

Example/simple setup #2

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions examples/simple-setup/main.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
module "github_actions_iam_role" {
source = "github.com/infraspecdev/terraform-aws-github-actions-iam-role?ref=main"
aws_account_id = var.aws_account_id
github_username = var.github_username
repository_names = var.repository_names
role_name = var.role_name
}
3 changes: 3 additions & 0 deletions examples/simple-setup/terraform.tfvars.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
aws_account_id = "ACCOUNT_ID"
github_username = "GITHUB_USERNAME"
repository_names = "["REPO_NAME_1","REPO_NAME_1"]"
20 changes: 20 additions & 0 deletions examples/simple-setup/variables.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
variable "aws_account_id" {
description = "The AWS Account ID"
type = string
}

variable "github_username" {
description = "GitHub Username"
type = string
}

variable "repository_names" {
description = "List of names of the GitHub repository that will be allowed to assume the role."
type = list(string)
}

variable "role_name" {
description = "Name of the IAM Role"
type = string
default = "GitHubActionsRole"
}