Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sparkfabrik/terraform-google-gcp-artifact-registry
Terraform Google GCP Artifact Registry
https://github.com/sparkfabrik/terraform-google-gcp-artifact-registry
Last synced: 23 days ago
JSON representation
Terraform Google GCP Artifact Registry
- Host: GitHub
- URL: https://github.com/sparkfabrik/terraform-google-gcp-artifact-registry
- Owner: sparkfabrik
- License: gpl-3.0
- Created: 2023-04-11T08:46:39.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-10-17T09:41:38.000Z (3 months ago)
- Last Synced: 2024-12-24T05:54:46.936Z (about 1 month ago)
- Language: HCL
- Size: 47.9 KB
- Stars: 0
- Watchers: 7
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Terraform GCP Artifact Registry
![tflint status](https://github.com/sparkfabrik/terraform-sparkfabrik-gcp-http-monitoring/actions/workflows/tflint.yml/badge.svg?branch=main)
This module enable Artifact Registry api in the GCP (Google Cloud Platform) project, create repositories and assign read and write IAM permissions.
You MUST configure the required "google" provider inside your root module.
This module is provided without any kind of warranty and is GPL3 licensed.
## Providers
| Name | Version |
|------|---------|
| [google](#provider\_google) | >= 5.26.0 |## Requirements
| Name | Version |
|------|---------|
| [terraform](#requirement\_terraform) | >= 1.3 |
| [google](#requirement\_google) | >= 5.26.0 |## Inputs
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| [artifact\_registry\_listers](#input\_artifact\_registry\_listers) | List of principals that can list Artifact Registry repositories. | `list(string)` | `[]` | no |
| [artifact\_registry\_listers\_custom\_role\_name](#input\_artifact\_registry\_listers\_custom\_role\_name) | Name of the custom role for Artifact Registry listers. | `string` | `"custom.artifactRegistryLister"` | no |
| [default\_location](#input\_default\_location) | The default location for the Artifact Registry repositories. | `string` | `"europe-west1"` | no |
| [enable\_api](#input\_enable\_api) | Enable the Artifact Registry API. | `bool` | `true` | no |
| [project\_id](#input\_project\_id) | The GCP project ID that hosts the Artifact Registry. | `string` | n/a | yes |
| [repositories](#input\_repositories) | List of Artifact Registry repositories to create. |map(object({| n/a | yes |
description = string
format = optional(string, "DOCKER")
mode = optional(string, "STANDARD_REPOSITORY")
cleanup_policy_dry_run = optional(bool, true)
cleanup_policies = optional(map(object({
action = optional(string, ""),
condition = optional(object({
tag_state = optional(string),
tag_prefixes = optional(list(string), []),
version_name_prefixes = optional(list(string), []),
package_name_prefixes = optional(list(string), []),
older_than = optional(string),
newer_than = optional(string),
}), {}),
most_recent_versions = optional(object({
package_name_prefixes = optional(list(string), []),
keep_count = optional(number, 0)
}), {})
})), {})
docker_immutable_tags = optional(bool, true)
virtual_repository_config = optional(map(object({
repository = string
priority = optional(number, 0)
})), null)
remote_repository_config_docker = optional(object({
description = optional(string, "")
custom_repository_uri = string
disable_upstream_validation = optional(bool, false)
username_password_credentials_username = optional(string, "")
username_password_credentials_password_secret_version = optional(string, "")
}), null)
readers = optional(list(string), [])
writers = optional(list(string), [])
location = optional(string, "")
}))## Outputs
| Name | Description |
|------|-------------|
| [custom\_role\_artifact\_registry\_lister\_id](#output\_custom\_role\_artifact\_registry\_lister\_id) | The ID of the custom role for Artifact Registry listers. The role is created only if the list of Artifact Registry listers is not empty. |
| [repositories](#output\_repositories) | The created Artifact Repository repositories. |## Resources
| Name | Type |
|------|------|
| [google_artifact_registry_repository.repositories](https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/artifact_registry_repository) | resource |
| [google_artifact_registry_repository_iam_member.member](https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/artifact_registry_repository_iam_member) | resource |
| [google_project_iam_binding.artifact_registry_lister](https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/project_iam_binding) | resource |
| [google_project_iam_custom_role.artifact_registry_lister](https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/project_iam_custom_role) | resource |
| [google_project_service.project](https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/project_service) | resource |## Modules
No modules.