Skip to content
This repository was archived by the owner on May 15, 2025. It is now read-only.

Latest commit

 

History

History
 
 

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

README.md

display_name AWS Region
description A parameter with human region names and icons
icon ../.icons/aws.svg
maintainer_github coder
verified true
tags
helper
parameter
regions
aws

AWS Region

A parameter with all AWS regions. This allows developers to select the region closest to them.

Customize the preselected parameter value:

module "aws-region" {
  count   = data.coder_workspace.me.start_count
  source  = "registry.coder.com/modules/aws-region/coder"
  version = "1.0.12"
  default = "us-east-1"
}

provider "aws" {
  region = module.aws_region.value
}

AWS Regions

Examples

Customize regions

Change the display name and icon for a region using the corresponding maps:

module "aws-region" {
  count   = data.coder_workspace.me.start_count
  source  = "registry.coder.com/modules/aws-region/coder"
  version = "1.0.12"
  default = "ap-south-1"

  custom_names = {
    "ap-south-1" : "Awesome Mumbai!"
  }

  custom_icons = {
    "ap-south-1" : "/emojis/1f33a.png"
  }
}

provider "aws" {
  region = module.aws_region.value
}

AWS Custom

Exclude regions

Hide the Asia Pacific regions Seoul and Osaka:

module "aws-region" {
  count   = data.coder_workspace.me.start_count
  source  = "registry.coder.com/modules/aws-region/coder"
  version = "1.0.12"
  exclude = ["ap-northeast-2", "ap-northeast-3"]
}

provider "aws" {
  region = module.aws_region.value
}

AWS Exclude

Related templates

For a complete AWS EC2 template, see the following examples in the Coder Registry.