https://github.com/hadenlabs/terraform-github-iam
github iam for terraform
https://github.com/hadenlabs/terraform-github-iam
github hadenlabs iam peru terraform terraform-modules
Last synced: 4 months ago
JSON representation
github iam for terraform
- Host: GitHub
- URL: https://github.com/hadenlabs/terraform-github-iam
- Owner: hadenlabs
- License: lgpl-3.0
- Created: 2021-02-16T13:35:44.000Z (almost 5 years ago)
- Default Branch: develop
- Last Pushed: 2022-02-28T03:55:49.000Z (almost 4 years ago)
- Last Synced: 2025-04-07T01:04:46.799Z (10 months ago)
- Topics: github, hadenlabs, iam, peru, terraform, terraform-modules
- Language: Go
- Homepage:
- Size: 415 KB
- Stars: 3
- Watchers: 2
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: docs/contributing.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Code of conduct: docs/code_of_conduct.md
Awesome Lists containing this project
README
[](https://github.com/hadenlabs/terraform-github-iam/releases) [](https://github.com/hadenlabs/terraform-github-iam/actions?workflow=lint-code) [](https://github.com/hadenlabs/terraform-github-iam/actions?workflow=ci) [](https://github.com/hadenlabs/terraform-github-iam/actions?workflow=test) [](https://github.com/pre-commit/pre-commit) [](https://conventionalcommits.org) [](https://keepachangelog.com)
# terraform-github-iam
Terraform module to provision an github iam.
## Requirements
This is a list of plugins that need to be installed previously to enjoy all the goodies of this configuration:
- [Pyenv](https://github.com/pyenv/pyenv)
- [Docker](https://www.docker.com/)
- [python](https://www.python.org)
- [taskfile](https://github.com/go-task/task)
## Usage
```hcl
module "main" {
source = "hadenlabs/iam/github"
version = "0.2.1"
providers = {
github = github
}
team = {
"name" = "name-team"
"description = "team description"
"privacy" = "closed"
}
maintainers = ["user-github"]
members = ["user-github"]
}
```
Full working examples can be found in [examples](./examples) folder.
## Examples
### common
```hcl
module "main" {
source = "hadenlabs/iam/github"
version = "0.2.1"
providers = {
github = github
}
team = {
"name" = "name-team"
"description = "team description"
"privacy" = "closed"
}
maintainers = ["user-github"]
members = ["user-github"]
}
```
### implement members, teams and permissions
```hcl
module "main" {
source = "hadenlabs/iam/github"
version = "0.2.1"
providers = {
github = github
}
team = {
"name" = "name-team"
"description = "team description"
"privacy" = "closed"
}
permissions = [
{
repository = "name repository",
permission = "pull",
},
]
maintainers = ["user-github"]
members = ["user-github"]
}
```
## Requirements
| Name | Version |
| ------------------------------------------------------------------------ | ------- |
| [terraform](#requirement_terraform) | >= 0.13 |
| [github](#requirement_github) | >=4.5.0 |
## Providers
| Name | Version |
| --------------------------------------------------------- | ------- |
| [github](#provider_github) | >=4.5.0 |
## Modules
No modules.
## Resources
| Name | Type |
| --- | --- |
| [github_team.this](https://registry.terraform.io/providers/integrations/github/latest/docs/resources/team) | resource |
| [github_team_membership.maintainers](https://registry.terraform.io/providers/integrations/github/latest/docs/resources/team_membership) | resource |
| [github_team_membership.members](https://registry.terraform.io/providers/integrations/github/latest/docs/resources/team_membership) | resource |
| [github_team_repository.this](https://registry.terraform.io/providers/integrations/github/latest/docs/resources/team_repository) | resource |
## Inputs
| Name | Description | Type | Default | Required |
| --- | --- | --- | --- | :-: |
| [maintainers](#input_maintainers) | This members role maintainers | `list(string)` | `[]` | no |
| [members](#input_members) | This members role member | `list(string)` | `[]` | no |
| [permissions](#input_permissions) | Add permissions of repository for team |
list(object({
repository = string
permission = string
})) | `[]` | no |
| [team](#input_team) | This team to create | object({
name = string
description = string
privacy = string
}) | n/a | yes |
## Outputs
| Name | Description |
| ----------------------------------------------------------------------- | -------------------------------------- |
| [maintainers](#output_maintainers) | instance of maintainers of team github |
| [members](#output_members) | instance of members of team github |
| [team](#output_team) | instance of team |
| [team_members](#output_team_members) | instance of members for team github |
## Help
**Got a question?**
File a GitHub [issue](https://github.com/hadenlabs/terraform-github-iam/issues).
## Contributing
### Bug Reports & Feature Requests
Please use the [issue tracker](https://github.com/hadenlabs/terraform-github-iam/issues) to report any bugs or file feature requests.
### Development
In general, PRs are welcome. We follow the typical "fork-and-pull" Git workflow.
1. **Fork** the repo on GitHub
2. **Clone** the project to your own machine
3. **Commit** changes to your own branch
4. **Push** your work back up to your fork
5. Submit a **Pull Request** so that we can review your changes
**NOTE:** Be sure to rebase the latest changes from "upstream" before making a pull request!
## Module Versioning
This Module follows the principles of [Semantic Versioning (SemVer)](https://semver.org/).
Using the given version number of `MAJOR.MINOR.PATCH`, we apply the following constructs:
1. Use the `MAJOR` version for incompatible changes.
1. Use the `MINOR` version when adding functionality in a backwards compatible manner.
1. Use the `PATCH` version when introducing backwards compatible bug fixes.
### Backwards compatibility in `0.0.z` and `0.y.z` version
- In the context of initial development, backwards compatibility in versions `0.0.z` is **not guaranteed** when `z` is increased. (Initial development)
- In the context of pre-release, backwards compatibility in versions `0.y.z` is **not guaranteed** when `y` is increased. (Pre-release)
## Copyright
Copyright © 2018-2021 [Hadenlabs](https://hadenlabs.com)
## Trademarks
All other trademarks referenced herein are the property of their respective owners.
## License
The code and styles are licensed under the LGPL-3.0 license [See project license.](LICENSE).
## Don't forget to 🌟 Star 🌟 the repo if you like terraform-github-iam
[Your feedback is appreciated](https://github.com/hadenlabs/terraform-github-iam/issues)