cloud-foundation-fabric/modules/__experimental_deprecated/cloud-identity-group-factory
Julio Castillo 3af7e257d2
Add tflint to pipelines (#2220)
* Fix terraform_deprecated_index

https://github.com/terraform-linters/tflint-ruleset-terraform/blob/v0.5.0/docs/rules/terraform_deprecated_index.md

* Fix terraform_deprecated_interpolation

Reference: https://github.com/terraform-linters/tflint-ruleset-terraform/blob/v0.5.0/docs/rules/terraform_deprecated_interpolation.md

* Fix more indexing

* Remove unused variable

* Enable TFLint for modules

* Add tflint config file

* Fix chdir

* Lint modules

* TFLint fixes

* TFLint

* Fixes binauthz README

* Fixes DNS response policy tests. Restores MIG outputs.

* Fixes other DNS response policy tests.

* Update tests for fast 2-e

* Moar fixed tests

---------

Co-authored-by: Simone Ruffilli <sruffilli@google.com>
2024-04-17 10:23:48 +02:00
..
README.md Factories refactor (#1843) 2024-02-26 10:16:52 +00:00
main.tf Add tflint to pipelines (#2220) 2024-04-17 10:23:48 +02:00
outputs.tf Factories refactor (#1843) 2024-02-26 10:16:52 +00:00
variables.tf Factories refactor (#1843) 2024-02-26 10:16:52 +00:00

README.md

Google Cloud Identity Group Factory

This module allows creation and management of Cloud Identity Groups by defining them in well formatted yaml files.

Yaml abstraction for Groups can simplify groups creation and members management. Yaml can be simpler and clearer comparing to HCL.

Example

Terraform code

module "groups" {
  source      = "./fabric/modules/__experimental_deprecated/cloud-identity-group-factory"
  customer_id = "customers/C0xxxxxxx"
  data_dir    = "data"
}
# tftest modules=2 resources=3 files=group1
# tftest-file id=group1 path=data/group1@example.com.yaml
display_name: Group 1
description: Group 1
members:
  - user1@example.com
managers:
  - user2@example.com

Configuration Structure

Groups configuration should be placed in a set of yaml files. The name of the file identify the name of the group.

├── data
    ├── group1@domain.com.yaml
    ├── group2@domain.com.yaml

Group definition format and structure

Within each file, the group entry structure is following:

display_name: Group 1 # Group display name.
description: Group 1 description # Group description.
members:  # List of group members.
  - user_1@example.com
  - user_2@example.com  
managers: # List of group managers.
  - manager_1@example.com

Variables

name description type required default
customer_id Directory customer ID in the form customers/C0xxxxxxx. string
data_dir Relative path for the folder storing configuration data. string

Outputs

name description sensitive
group_id Group name => Group ID mapping.