Skip to content
This repository has been archived by the owner on Jan 25, 2023. It is now read-only.

Commit

Permalink
Merge pull request #94 from hashicorp/tf14
Browse files Browse the repository at this point in the history
Terraform v0.14 update
  • Loading branch information
brikis98 authored Apr 13, 2021
2 parents bf3ee5f + e5fb890 commit dad57de
Show file tree
Hide file tree
Showing 9 changed files with 86 additions and 44 deletions.
12 changes: 2 additions & 10 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
defaults: &defaults
docker:
- image: 087285199408.dkr.ecr.us-east-1.amazonaws.com/circle-ci-test-image-base:tf13.4

- image: 087285199408.dkr.ecr.us-east-1.amazonaws.com/circle-ci-test-image-base:go1.16-go111module
version: 2
jobs:
test:
<<: *defaults
steps:
- checkout

- run:
# Fail the build if the pre-commit hooks don't pass. Note: if you run $ pre-commit install locally within this repo, these hooks will
# execute automatically every time before you commit, ensuring the build never fails at this step!
Expand All @@ -17,21 +15,17 @@ jobs:
pip install pre-commit==1.21.0 cfgv==2.0.1
pre-commit install
pre-commit run --all-files
- run:
name: create log directory
command: mkdir -p /tmp/logs

- run:
name: run tests
command: run-go-tests --path test --timeout 2h | tee /tmp/logs/all.log
no_output_timeout: 3600s

- store_artifacts:
path: /tmp/logs
- store_test_results:
path: /tmp/logs

path: /tmp/logs
deploy:
<<: *defaults
steps:
Expand All @@ -40,14 +34,12 @@ jobs:
- run: sudo -E gruntwork-install --module-name "aws-helpers" --repo "https://github.com/gruntwork-io/module-ci" --tag "v0.29.0"
- run: sudo -E gruntwork-install --module-name "git-helpers" --repo "https://github.com/gruntwork-io/module-ci" --tag "v0.29.0"
- run: sudo -E gruntwork-install --module-name "build-helpers" --repo "https://github.com/gruntwork-io/module-ci" --tag "v0.29.0"

# We generally only want to build AMIs on new releases, but when we are setting up AMIs in a new account for the
# first time, we want to build the AMIs but NOT run automated tests, since those tests will fail without an existing
# AMI already in the AWS Account.
- run: _ci/publish-amis.sh "ubuntu16-ami"
- run: _ci/publish-amis.sh "ubuntu18-ami"
- run: _ci/publish-amis.sh "amazon-linux-2-ami"

workflows:
version: 2
build-and-test:
Expand Down
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,7 @@ out/
vendor

# Folder used to store temporary test data by Terratest
.test-data
.test-data
# Ignore Terraform lock files, as we want to test the Terraform code in these repos with the latest provider
# versions.
.terraform.lock.hcl
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# Nomad AWS Module

[![Maintained by Gruntwork.io](https://img.shields.io/badge/maintained%20by-gruntwork.io-%235849a6.svg)](https://gruntwork.io/?ref=repo_aws_nomad)
![Terraform Version](https://img.shields.io/badge/tf-%3E%3D0.12.0-blue.svg)
![Terraform Version](https://img.shields.io/badge/tf-%3E%3D0.14.0-blue.svg)

This repo contains a set of modules for deploying a [Nomad](https://www.nomadproject.io/) cluster on
[AWS](https://aws.amazon.com/) using [Terraform](https://www.terraform.io/). Nomad is a distributed, highly-available
Expand Down
4 changes: 2 additions & 2 deletions examples/nomad-consul-separate-cluster/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
# REQUIRE A SPECIFIC TERRAFORM VERSION OR HIGHER
# ----------------------------------------------------------------------------------------------------------------------
terraform {
# This module is now only being tested with Terraform 0.13.x. However, to make upgrading easier, we are setting
# This module is now only being tested with Terraform 0.14.x. However, to make upgrading easier, we are setting
# 0.12.26 as the minimum version, as that version added support for required_providers with source URLs, making it
# forwards compatible with 0.13.x code.
# forwards compatible with 0.14.x code.
required_version = ">= 0.12.26"
}

Expand Down
4 changes: 2 additions & 2 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
# REQUIRE A SPECIFIC TERRAFORM VERSION OR HIGHER
# ----------------------------------------------------------------------------------------------------------------------
terraform {
# This module is now only being tested with Terraform 0.13.x. However, to make upgrading easier, we are setting
# This module is now only being tested with Terraform 0.14.x. However, to make upgrading easier, we are setting
# 0.12.26 as the minimum version, as that version added support for required_providers with source URLs, making it
# forwards compatible with 0.13.x code.
# forwards compatible with 0.14.x code.
required_version = ">= 0.12.26"
}

Expand Down
4 changes: 2 additions & 2 deletions modules/nomad-cluster/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
# REQUIRE A SPECIFIC TERRAFORM VERSION OR HIGHER
# ----------------------------------------------------------------------------------------------------------------------
terraform {
# This module is now only being tested with Terraform 0.13.x. However, to make upgrading easier, we are setting
# This module is now only being tested with Terraform 0.14.x. However, to make upgrading easier, we are setting
# 0.12.26 as the minimum version, as that version added support for required_providers with source URLs, making it
# forwards compatible with 0.13.x code.
# forwards compatible with 0.14.x code.
required_version = ">= 0.12.26"
}

Expand Down
4 changes: 2 additions & 2 deletions modules/nomad-security-group-rules/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
# REQUIRE A SPECIFIC TERRAFORM VERSION OR HIGHER
# ----------------------------------------------------------------------------------------------------------------------
terraform {
# This module is now only being tested with Terraform 0.13.x. However, to make upgrading easier, we are setting
# This module is now only being tested with Terraform 0.14.x. However, to make upgrading easier, we are setting
# 0.12.26 as the minimum version, as that version added support for required_providers with source URLs, making it
# forwards compatible with 0.13.x code.
# forwards compatible with 0.14.x code.
required_version = ">= 0.12.26"
}

Expand Down
2 changes: 1 addition & 1 deletion test/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ module github.com/gruntwork-io/terraform-aws-nomad/test

go 1.13

require github.com/gruntwork-io/terratest v0.30.11
require github.com/gruntwork-io/terratest v0.31.3
Loading

0 comments on commit dad57de

Please sign in to comment.