diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 5554fc0..ea49b11 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -8,10 +8,10 @@ on: jobs: create_github_release: name: Create Github Release - runs-on: ubuntu-20.04 + runs-on: ubuntu-24.04 steps: - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Determine Version id: determine_version shell: bash diff --git a/.github/workflows/validate.yaml b/.github/workflows/validate.yaml index 40134da..7163e91 100644 --- a/.github/workflows/validate.yaml +++ b/.github/workflows/validate.yaml @@ -9,16 +9,29 @@ on: jobs: validate: name: Validate Terraform Module - runs-on: ubuntu-20.04 + runs-on: ubuntu-24.04 + strategy: + matrix: + tf_version: + - docker.io/hashicorp/terraform:1.7 + - docker.io/hashicorp/terraform:latest + - ghcr.io/opentofu/opentofu:latest container: - image: docker.io/hashicorp/terraform:0.13.2 + image: ${{ matrix.tf_version }} steps: - name: git checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 + - name: Prepare environment + shell: bash + run: | + tf_exe="$(command -v 'tofu' || command -v 'terraform')" + echo "TF_EXE="${tf_exe}" >> "${GITHUB_ENV}" - name: Initialize Terraform - run: terraform init -backend=false + run: | + "${TF_EXE}" init -backend=false - name: Validate Terraform Module Syntax - run: terraform validate + run: | + "${TF_EXE}" validate #security_scanner: # name: Run tfsec Security Scanner # runs-on: ubuntu-20.04 diff --git a/.gitignore b/.gitignore index 2b187d2..d115daf 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ /.terraform/ +/.terraform.lock.hcl *.tfstate* *.auto.tfvars diff --git a/.vscode/extensions.json b/.vscode/extensions.json index fc48456..99f79af 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -2,7 +2,6 @@ "recommendations": [ "davidanson.vscode-markdownlint", "editorconfig.editorconfig", - "mauve.terraform" - + "hashicorp.terraform" ] } diff --git a/CHANGELOG.md b/CHANGELOG.md index 8b52a03..645fe60 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,10 +5,31 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [4.0.0] - 2024-08-12 + +The source code of the module has been transferred to a new Github organization. + +This is the first release that requires at least Terraform 1.7.0. + +### Fixed + +- Block types within pod template spec `limits` and `requests` have been converted to + arguments, which fixes errors with current versions of the Kubernetes provider plugin. + ([#10](https://github.com/qvest-digital/terraform-kubernetes-aws-node-termination-handler/issues/10)) + +### Changed + +- Github organization hosting this module has been changed to [`qvest-digital`](https://github.com/qvest-digital). +- Terraform 1.7.0 or higher is required to use this module. + +### Updated + +- Default version of the aws-node-termination-handler has been set to v1.22.1. + ## [3.0.0] - 2020-10-23 This is the first release that requires at least Terraform 0.13.0. -The latest compatibiliy releases in the 0.12 series (0.12.29 as this release is being made) +The latest compatibility releases in the 0.12 series (0.12.29 as this release is being made) might work, but it is no longer officially supported by the module's maintainers. ### Changed @@ -17,7 +38,7 @@ might work, but it is no longer officially supported by the module's maintainers ### Added -- Webhook configuration options can be specified as input variables. ([#6](https://github.com/iplabs/terraform-kubernetes-aws-node-termination-handler/issues/6)) +- Webhook configuration options can be specified as input variables. ([#6](https://github.com/qvest-digital/terraform-kubernetes-aws-node-termination-handler/issues/6)) ### Updated @@ -30,7 +51,7 @@ Thanks for the fix, [Nigel](https://github.com/nigelellis)! ### Fixed - A bug in the ClusterRoleBinding where the name of the service account and - it's namespace got mixed up, was corrected. ([#5](https://github.com/iplabs/terraform-kubernetes-aws-node-termination-handler/issues/5)) + it's namespace got mixed up, was corrected. ([#5](https://github.com/qvest-digital/terraform-kubernetes-aws-node-termination-handler/issues/5)) ## [2.1.0] - 2020-09-08 @@ -45,7 +66,7 @@ Thanks for the fix, [Nigel](https://github.com/nigelellis)! ## Fixed -- Specify `host_post` to avoid perpetual diffs. ([#3](https://github.com/iplabs/terraform-kubernetes-aws-node-termination-handler/issues/3)) +- Specify `host_post` to avoid perpetual diffs. ([#3](https://github.com/qvest-digital/terraform-kubernetes-aws-node-termination-handler/issues/3)) ## [2.0.0] - 2020-07-15 diff --git a/README.md b/README.md index c4b8233..ca1be44 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ snippet might be used. ```hcl module "aws_node_termination_handler" { - source = "iplabs/aws-node-termination-handler/kubernetes" - version = "2.1.1" + source = "qvest-digital/aws-node-termination-handler/kubernetes" + version = "4.0.0" } ``` diff --git a/main.tf b/main.tf index 97a55d1..74b4738 100644 --- a/main.tf +++ b/main.tf @@ -256,11 +256,11 @@ resource "kubernetes_daemonset" "this" { protocol = "TCP" } resources { - limits { + limits = { cpu = "100m" memory = "128Mi" } - requests { + requests = { cpu = "50m" memory = "64Mi" } diff --git a/variables.tf b/variables.tf index d886f0b..0d9768c 100644 --- a/variables.tf +++ b/variables.tf @@ -1,7 +1,7 @@ variable "node_termination_handler_version" { description = "The version to use. See https://github.com/aws/aws-node-termination-handler/releases for available versions" type = string - default = "1.9.0" + default = "1.22.1" } variable "ignore_daemon_sets" { diff --git a/versions.tf b/versions.tf index 84dd84d..46ace14 100644 --- a/versions.tf +++ b/versions.tf @@ -1,5 +1,5 @@ terraform { - required_version = ">= 0.12.29" + required_version = ">= 1.7.0" required_providers { kubernetes = { source = "hashicorp/kubernetes"