https://github.com/math280h/terraform-github-action-secrets
Easily manage secrets on multiple repositories via terraform
https://github.com/math280h/terraform-github-action-secrets
Last synced: about 1 year ago
JSON representation
Easily manage secrets on multiple repositories via terraform
- Host: GitHub
- URL: https://github.com/math280h/terraform-github-action-secrets
- Owner: math280h
- License: mit
- Created: 2022-06-22T13:56:27.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2022-06-22T14:00:29.000Z (about 4 years ago)
- Last Synced: 2025-04-03T17:50:30.717Z (about 1 year ago)
- Language: HCL
- Homepage: https://registry.terraform.io/modules/math280h/action-secrets/github
- Size: 2.93 KB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# terraform-github-action-secrets
Easily manage secrets across multiple repositories with shared and unique secrets.
## How to use
All secrets stored under the "all" object will be applied to all repositories.
To add secrets that only go to one repository add an object (In the example, see "test") that contains the unique secrets
```hcl
terraform {
required_providers {
github = {
source = "integrations/github"
version = "~> 4.0"
}
}
}
# Remember the repository owner always defaults to the key owner
# define the owner attribute if you need another
provider "github" {
token = var.token
}
module "github-secrets" {
source = "math280h/action-secrets/github"
version = "0.0.1"
# In this example this would point to one repository with the full name
# math280h/test
# And two secrets would be created, "test" from the "all" object and
# since the name matches, "test1" from the "test" object.
repositories = [{ name = "test" }]
secrets = { "all" = { "test" = "test" }, "test" = { "test1" = "test1" } }
}
```