Azure module to deploy a Azure Shared Image Gallery.
Module version | Terraform version | OpenTofu version | AzureRM version |
---|---|---|---|
>= 8.x.x | Unverified | 1.8.x | >= 4.0 |
>= 7.x.x | 1.3.x | >= 3.0 | |
>= 6.x.x | 1.x | >= 3.0 | |
>= 5.x.x | 0.15.x | >= 2.0 | |
>= 4.x.x | 0.13.x / 0.14.x | >= 2.0 | |
>= 3.x.x | 0.12.x | >= 2.0 | |
>= 2.x.x | 0.12.x | < 2.0 | |
< 2.x.x | 0.11.x | < 2.0 |
If you want to contribute to this repository, feel free to use our pre-commit git hook configuration which will help you automatically update and format some files for you by enforcing our Terraform code module best-practices.
More details are available in the CONTRIBUTING.md file.
This module is optimized to work with the Claranet terraform-wrapper tool
which set some terraform variables in the environment needed by this module.
More details about variables set by the terraform-wrapper
available in the documentation.
module "azure_region" {
source = "claranet/regions/azurerm"
version = "x.x.x"
azure_region = var.azure_region
}
module "rg" {
source = "claranet/rg/azurerm"
version = "x.x.x"
location = module.azure_region.location
client_name = var.client_name
environment = var.environment
stack = var.stack
}
module "run" {
source = "claranet/run/azurerm"
version = "x.x.x"
client_name = var.client_name
environment = var.environment
stack = var.stack
location = module.azure_region.location
location_short = module.azure_region.location_short
resource_group_name = module.rg.resource_group_name
}
module "shared_image_gallery" {
source = "claranet/shared-image-gallery/azurerm"
version = "x.x.x"
location = module.azure_region.location
location_short = module.azure_region.location_short
resource_group_name = module.rg.resource_group_name
client_name = var.client_name
environment = var.environment
stack = var.stack
shared_images_definitions = [
{
name = "Debian11"
identifier = {
offer = "Debian"
publisher = "Claranet"
sku = "11"
}
os_type = "Linux"
description = "Claranet's Debian 11 custom image."
},
{
name = "Debian12"
identifier = {
offer = "Debian"
publisher = "Claranet"
sku = "12"
}
os_type = "Linux"
description = "Claranet's Debian 12 custom image."
},
]
extra_tags = {
foo = "bar"
}
}
Name | Version |
---|---|
azurecaf | ~> 1.2, >= 1.2.22 |
azurerm | ~> 3.74 |
No modules.
Name | Type |
---|---|
azurerm_shared_image.shared_image | resource |
azurerm_shared_image_gallery.shared_image_gallery | resource |
azurecaf_name.shared_image_gallery | data source |
Name | Description | Type | Default | Required |
---|---|---|---|---|
client_name | Client name/account used in naming. | string |
n/a | yes |
community_gallery | Configure the Shared Image Gallery as a Community Gallery. | object({ |
null |
no |
custom_name | Custom Azure Shared Image Gallery, generated if not set | string |
"" |
no |
default_tags_enabled | Option to enable or disable default tags. | bool |
true |
no |
environment | Project environment. | string |
n/a | yes |
extra_tags | Additional tags to add on resources. | map(string) |
{} |
no |
location | Azure region to use. | string |
n/a | yes |
location_short | Short string for Azure location. | string |
n/a | yes |
name_prefix | Optional prefix for the generated name | string |
"" |
no |
name_suffix | Optional suffix for the generated name | string |
"" |
no |
resource_group_name | Name of the resource group. | string |
n/a | yes |
shared_image_gallery_description | A description for this Shared Image Gallery. | string |
null |
no |
shared_images_definitions | Create Shared Image Definition. | list(object({ |
[] |
no |
stack | Project stack name. | string |
n/a | yes |
Name | Description |
---|---|
id | Azure Shared Image Gallery ID |
name | Azure Shared Image Gallery name |
shared_image_gallery | Azure Shared Image Gallery output object |
shared_images_definitions | Azure Shared Images definitions |
Microsoft Azure documentation: xxxx