Skip to content

Commit

Permalink
Update Atmos to the latest version. Update tests (#311)
Browse files Browse the repository at this point in the history
* Update Atmos

* Update Atmos

* Updates

* Updates

* Updates

* Updates
  • Loading branch information
aknysh authored Jul 18, 2023
1 parent 2e1d546 commit 6f0f398
Show file tree
Hide file tree
Showing 53 changed files with 1,304 additions and 353 deletions.
2 changes: 0 additions & 2 deletions docs/data-sources/aws_eks_update_kubeconfig.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,5 +127,3 @@ data "utils_aws_eks_update_kubeconfig" "example4" {

- `id` (String) The ID of this resource.
- `output` (String) Output.


2 changes: 0 additions & 2 deletions docs/data-sources/component_config.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,5 +81,3 @@ data "utils_component_config" "example3" {

- `id` (String) The ID of this resource.
- `output` (String) Component configuration.


2 changes: 0 additions & 2 deletions docs/data-sources/deep_merge_json.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,3 @@ data "utils_deep_merge_json" "example" {

- `id` (String) The ID of this resource.
- `output` (String) The deep-merged output.


2 changes: 0 additions & 2 deletions docs/data-sources/deep_merge_yaml.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,3 @@ data "utils_deep_merge_yaml" "example" {

- `id` (String) The ID of this resource.
- `output` (String) The deep-merged output.


6 changes: 2 additions & 4 deletions docs/data-sources/describe_stacks.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,13 +69,13 @@ data "utils_describe_stacks" "example6" {
stage = local.stage
component_types = ["terraform"]
components = ["test/test-component-override-3"]
sections = ["vars", "metadata", "env"]
sections = ["vars", "metadata", "env", "workspace"]
}
data "utils_describe_stacks" "example7" {
component_types = ["terraform"]
components = ["top-level-component1"]
sections = ["vars"]
sections = ["vars", "workspace"]
}
```

Expand All @@ -101,5 +101,3 @@ data "utils_describe_stacks" "example7" {

- `id` (String) The ID of this resource.
- `output` (String) Stack configurations.


2 changes: 0 additions & 2 deletions docs/data-sources/spacelift_stack_config.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,3 @@ data "utils_spacelift_stack_config" "example" {

- `id` (String) The ID of this resource.
- `output` (String) A map of Spacelift stack configurations.


2 changes: 0 additions & 2 deletions docs/data-sources/stack_config_yaml.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,5 +54,3 @@ data "utils_stack_config_yaml" "example" {

- `id` (String) The ID of this resource.
- `output` (List of String) A list of stack configurations.


Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ spec:
# In 'uri', Golang templates are supported https://pkg.go.dev/text/template
# If 'version' is provided, '{{.Version}}' will be replaced with the 'version' value before pulling the files from 'uri'
uri: github.com/cloudposse/terraform-aws-components.git//modules/account-map?ref={{.Version}}
version: 1.91.0
version: 1.240.0
# Only include the files that match the 'included_paths' patterns
# If 'included_paths' is not specified, all files will be matched except those that match the patterns from 'excluded_paths'
# 'included_paths' support POSIX-style Globs for file names/paths (double-star `**` is supported)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ spec:
# In 'uri', Golang templates are supported https://pkg.go.dev/text/template
# If 'version' is provided, '{{.Version}}' will be replaced with the 'version' value before pulling the files from 'uri'
uri: github.com/cloudposse/terraform-aws-components.git//modules/vpc-flow-logs-bucket?ref={{.Version}}
version: 1.91.0
version: 1.240.0
# Only include the files that match the 'included_paths' patterns
# If 'included_paths' is not specified, all files will be matched except those that match the patterns from 'excluded_paths'
# 'included_paths' support POSIX-style Globs for file names/paths (double-star `**` is supported)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module "flow_logs_s3_bucket" {
source = "cloudposse/vpc-flow-logs-s3-bucket/aws"
version = "0.12.0"
version = "0.18.0"

lifecycle_prefix = var.lifecycle_prefix
lifecycle_tags = var.lifecycle_tags
Expand All @@ -12,7 +12,6 @@ module "flow_logs_s3_bucket" {
expiration_days = var.expiration_days
traffic_type = var.traffic_type
force_destroy = var.force_destroy
arn_format = var.arn_format
flow_log_enabled = false

context = module.this.context
Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
provider "aws" {
region = var.region

# `terraform import` will not use data from a data source, so on import we have to explicitly specify the profile
profile = coalesce(var.import_profile_name, module.iam_roles.terraform_profile_name)
# Profile is deprecated in favor of terraform_role_arn. When profiles are not in use, terraform_profile_name is null.
profile = module.iam_roles.terraform_profile_name

dynamic "assume_role" {
# module.iam_roles.terraform_role_arn may be null, in which case do not assume a role.
for_each = compact([module.iam_roles.terraform_role_arn])
content {
role_arn = assume_role.value
}
}
}

module "iam_roles" {
source = "../account-map/modules/iam-roles"
context = module.this.context
}

variable "import_profile_name" {
type = string
default = null
description = "AWS Profile to use when importing a resource"
}

Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,3 @@ variable "traffic_type" {
description = "The type of traffic to capture. Valid values: `ACCEPT`, `REJECT`, `ALL`"
default = "ALL"
}

variable "arn_format" {
type = string
default = "arn:aws"
description = "ARN format to be used. May be changed to support deployment in GovCloud/China regions"
}
Original file line number Diff line number Diff line change
@@ -1,18 +1,10 @@
terraform {
required_version = ">= 0.13.0"
required_version = ">= 1.0.0"

required_providers {
aws = {
source = "hashicorp/aws"
version = ">= 3.0"
}
template = {
source = "cloudposse/template"
version = ">= 2.2"
}
local = {
source = "hashicorp/local"
version = ">= 1.3"
version = ">= 4.9.0"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ spec:
# In 'uri', Golang templates are supported https://pkg.go.dev/text/template
# If 'version' is provided, '{{.Version}}' will be replaced with the 'version' value before pulling the files from 'uri'
uri: github.com/cloudposse/terraform-aws-components.git//modules/vpc?ref={{.Version}}
version: 1.91.0
version: 1.240.0
# Only include the files that match the 'included_paths' patterns
# If 'included_paths' is not specified, all files will be matched except those that match the patterns from 'excluded_paths'
# 'included_paths' support POSIX-style Globs for file names/paths (double-star `**` is supported)
Expand Down
9 changes: 4 additions & 5 deletions examples/complete/components/terraform/infra/vpc/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ module "utils" {

module "vpc" {
source = "cloudposse/vpc/aws"
version = "2.0.0"
version = "2.1.0"

ipv4_primary_cidr_block = var.ipv4_primary_cidr_block
internet_gateway_enabled = var.public_subnets_enabled
Expand All @@ -94,7 +94,7 @@ module "endpoint_security_groups" {
for_each = local.enabled && try(length(var.interface_vpc_endpoints), 0) > 0 ? toset([local.interface_endpoint_security_group_key]) : []

source = "cloudposse/security-group/aws"
version = "2.0.0-rc1"
version = "2.2.0"

create_before_destroy = true
preserve_security_group_id = false
Expand All @@ -119,10 +119,9 @@ module "endpoint_security_groups" {
context = module.this.context
}


module "vpc_endpoints" {
source = "cloudposse/vpc/aws//modules/vpc-endpoints"
version = "2.0.0"
version = "2.1.0"

enabled = (length(var.interface_vpc_endpoints) + length(var.gateway_vpc_endpoints)) > 0

Expand All @@ -135,7 +134,7 @@ module "vpc_endpoints" {

module "subnets" {
source = "cloudposse/dynamic-subnets/aws"
version = "2.0.4"
version = "2.4.1"

availability_zones = local.availability_zones
availability_zone_ids = local.availability_zone_ids
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ module "vpc_flow_logs_bucket" {
count = var.vpc_flow_logs_enabled ? 1 : 0

source = "cloudposse/stack-config/yaml//modules/remote-state"
version = "1.3.1"
version = "1.4.3"

component = var.vpc_flow_logs_bucket_component_name
stage = try(coalesce(var.vpc_flow_logs_bucket_stage_name, module.this.stage), null)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ module "service_1_label" {
}

module "service_2_label" {
source = "cloudposse/label/null"
version = "0.25.0"
source = "../../../modules/label"

name = var.service_2_name

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ output "service_1_id" {
}

output "service_2_id" {
value = module.service_2_label.id
value = module.service_2_label.label.id
description = "Service 2 ID"
}
Loading

0 comments on commit 6f0f398

Please sign in to comment.