Skip to content

Releases: terraform-linters/tflint

v0.51.1

11 May 13:34
Compare
Choose a tag to compare

What's Changed

Bug Fixes

  • terraform: Fix provider::terraform::* function names by @wata727 in #2046

Chores

Full Changelog: v0.51.0...v0.51.1

v0.51.0

02 May 15:48
Compare
Choose a tag to compare

What's Changed

This release includes many new features including parallelization of recursion inspection and support for Terraform v1.8.

Also, please be aware that there are important changes regarding licensing. TFLint has updated the embedded Terraform package to the latest version for Terraform v1.6+ support. As a result, we will be affected by Terraform's license change to BUSL announced by Hashicorp in August 2023.

Most of the code in TFLint is still licensed under MPL 2.0, but some files under the Terraform package are now licensed under BUSL 1.1. This means that release binaries are bound by both licenses and may be subject to Hashicorp's BUSL restrictions. If you have concerns about this change, we recommend reviewing the licensing implications before updating. Please note that we cannot provide legal advice.

Please refer to the discussion in https://github.com/terraform-linters/tflint/discussions/1826 and #1878 for details.

Enhancements

  • config: Add TFLint required_version settings by @wata727 in #2027
    • The required_version attribute can now be set in .tflint.hcl. This is useful for enforcing the version of TFLint that is actually used.
  • plugin: Add support for host-specific GitHub tokens by @wata727 in #2025
    • Environment variables like GITHUB_TOKEN_example_com have been introduced for GitHub Enterprise Server support.
  • Recursive inspection in parallel by @wata727 in #2021
    • The --recursive inspection now runs in parallel according to the number of CPU cores by default. The number of parallels can be changed with --max-workers.
  • terraform: Add support for Terraform v1.6/v1.7/v1.8 by @wata727 in #2030
    • New Terraform features are now supported, including provider-defined functions. Please note that support for provider-defined functions requires the latest HCL parser, so you may need to update your plugin versions.
    • Updated embedded Terraform packages to support Terraform v1.6+. As a result, TFLint now includes code for Hashicorp's BUSL 1.1.

Changes

  • Add warnings to --module/--no-module and module attribute by @wata727 in #1951
    • If you see a warning, use --call-module-type instead. The --module is equivalent to --call-module-type=all and the --no-module is equivalent to --call-module-type=none. This also applies to .tflint.hcl.

Chores

  • build: use go1.22 by @chenrui333 in #1977
  • workflows: remove cache: true for setup-go (default) by @chenrui333 in #1979
  • install: enable pipefail catch curl errors by @Ry4an in #1978
  • build(deps): Bump golang.org/x/oauth2 from 0.16.0 to 0.17.0 by @dependabot in #1981
  • build(deps): Bump golangci/golangci-lint-action from 3.7.0 to 4.0.0 by @dependabot in #1980
  • build(deps): Bump google.golang.org/grpc from 1.61.0 to 1.61.1 by @dependabot in #1987
  • sarif: add schema to repo by @bendrucker in #2000
  • build(deps): Bump google.golang.org/grpc from 1.61.1 to 1.62.0 by @dependabot in #1992
  • build(deps): Bump github.com/hashicorp/hcl/v2 from 2.19.1 to 2.20.0 by @dependabot in #1999
  • build(deps): Bump github.com/zclconf/go-cty from 1.14.2 to 1.14.3 by @dependabot in #1998
  • build(deps): Bump golang.org/x/crypto from 0.19.0 to 0.21.0 by @dependabot in #2001
  • build(deps): Bump golang.org/x/oauth2 from 0.17.0 to 0.18.0 by @dependabot in #2002
  • build(deps): Bump google.golang.org/grpc from 1.62.0 to 1.62.1 by @dependabot in #2003
  • build(deps): Bump github.com/zclconf/go-cty from 1.14.3 to 1.14.4 by @dependabot in #2009
  • build(deps): Bump github.com/hashicorp/hcl/v2 from 2.20.0 to 2.20.1 by @dependabot in #2012
  • build(deps): Bump google.golang.org/grpc from 1.62.1 to 1.63.0 by @dependabot in #2014
  • build(deps): Bump golang.org/x/crypto from 0.21.0 to 0.22.0 by @dependabot in #2016
  • build(deps): Bump golang.org/x/oauth2 from 0.18.0 to 0.19.0 by @dependabot in #2015
  • build(deps): Bump sigstore/cosign-installer from 3.4.0 to 3.5.0 by @dependabot in #2022
  • build(deps): Bump google.golang.org/grpc from 1.63.0 to 1.63.2 by @dependabot in #2023
  • build(deps): Bump golang.org/x/net from 0.22.0 to 0.23.0 by @dependabot in #2024
  • build(deps): Bump github.com/hashicorp/go-getter from 1.7.2 to 1.7.4 by @dependabot in #2026
  • build(deps): Bump golangci/golangci-lint-action from 4.0.0 to 5.1.0 by @dependabot in #2029
  • Pin Go patch version in go.mod by @wata727 in #2031
  • build(deps): Bump github.com/terraform-linters/tflint-plugin-sdk from 0.18.0 to 0.20.0 by @dependabot in #2032
  • build(deps): Bump github.com/terraform-linters/tflint-ruleset-terraform from 0.5.0 to 0.7.0 by @dependabot in #2033

New Contributors

Full Changelog: v0.50.3...v0.51.0

v0.50.3

05 Feb 18:49
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.50.2...v0.50.3

v0.50.2

21 Jan 12:55
Compare
Choose a tag to compare

What's Changed

Bug Fixes

  • Fix a bug where auto-fixed code could not be retrieved via GetFile API by @wata727 in #1959

Chores

  • build(deps): Bump github.com/cloudflare/circl from 1.3.3 to 1.3.7 by @dependabot in #1954
  • build(deps): Bump golang.org/x/oauth2 from 0.15.0 to 0.16.0 by @dependabot in #1956

Full Changelog: v0.50.1...v0.50.2

v0.50.1

08 Jan 13:10
Compare
Choose a tag to compare

What's Changed

BugFixes

Full Changelog: v0.50.0...v0.50.1

v0.50.0

23 Dec 14:20
Compare
Choose a tag to compare

What's Changed

Breaking Changes

  • Call local modules by default by @wata727 in #1918
    • Module inspection is now enabled by default for modules whose source is a relative path. Note that "module inspection" will be called "calling modules" after this change. See also #1066
    • CLI flag --module has been changed to --call-module-type. For backward compatibility, --module will continue to work, but it will be removed in a future version, so we recommend migrating early. The same applies to the module attribute of the configuration file.
      • --module flag is replaced by --call-module-type=all and --no-module (previous default) is replaced by --call-module-type=none
    • For modules with many local module calls, this change may result in performance degradation. If this is not acceptable, you can keep the previous default by specifying --call-module-type=none.
  • Make assignments to undeclared variables an error by @wata727 in #1941
    • In line with Terraform behavior, assignments using the --var flag etc. to undeclared variables now result in an error. To avoid this, remove unnecessary variable assignments.

Enhancements

  • Print the working directory on error in recursive inspection by @wata727 in #1933
  • Enable per-runner parallelism by @wata727 in #1944

BugFixes

  • Exit with an error if the explicitly passed .tflint.hcl does not exist by @wata727 in #1940

Chores

  • build(deps): Bump golang.org/x/oauth2 from 0.13.0 to 0.14.0 by @dependabot in #1913
  • build(deps): Bump sigstore/cosign-installer from 3.1.2 to 3.2.0 by @dependabot in #1915
  • build(deps): Bump github.com/hashicorp/go-plugin from 1.5.2 to 1.6.0 by @dependabot in #1917
  • docs: Remove mention of directory arguments by @wata727 in #1921
  • build(deps): Bump golang.org/x/crypto from 0.15.0 to 0.16.0 by @dependabot in #1923
  • build(deps): Bump golang.org/x/oauth2 from 0.14.0 to 0.15.0 by @dependabot in #1931
  • build(deps): Bump github.com/spf13/afero from 1.10.0 to 1.11.0 by @dependabot in #1932
  • build(deps): Bump actions/setup-go from 4 to 5 by @dependabot in #1936
  • build(deps): Bump sigstore/cosign-installer from 3.2.0 to 3.3.0 by @dependabot in #1937
  • build(deps): Bump alpine from 3.18 to 3.19 by @dependabot in #1938
  • Stop using backticks for emphasis by @wata727 in #1934
  • Avoid escaping newlines by @wata727 in #1942
  • build(deps): Bump golang.org/x/crypto from 0.16.0 to 0.17.0 by @dependabot in #1945
  • build(deps): Bump github.com/google/uuid from 1.4.0 to 1.5.0 by @dependabot in #1947
  • build(deps): Bump google.golang.org/grpc from 1.59.0 to 1.60.1 by @dependabot in #1948

Full Changelog: v0.49.0...v0.50.0

v0.49.0

12 Nov 15:36
Compare
Choose a tag to compare

What's Changed

Enhancements

  • build(deps): Bump github.com/terraform-linters/tflint-ruleset-terraform from 0.4.0 to 0.5.0 by @dependabot in #1883
    • This change updates the bundled terraform plugin version
  • feat(annotations): Allow a comment at the end of a tflint-ignore annotation by @papkos in #1892
  • tflint: Allow config file to be set via TFLINT_CONFIG_FILE by @wata727 in #1903
  • tflint: Add tflint-ignore-file annotation by @wata727 in #1909

Chores

  • Add formula-path to follow formula path changes by @wata727 in #1835
  • build(deps): Bump sigstore/cosign-installer from 3.1.1 to 3.1.2 by @dependabot in #1839
  • build(deps): Bump actions/checkout from 3 to 4 by @dependabot in #1838
  • Fix go directive to include patch version by @wata727 in #1842
  • Replace golang.org/x/exp/slices to slices package by @wata727 in #1836
  • build(deps): Bump github.com/hashicorp/go-plugin from 1.4.10 to 1.5.1 by @dependabot in #1846
  • build(deps): Bump golang.org/x/oauth2 from 0.11.0 to 0.12.0 by @dependabot in #1843
  • build(deps): Bump github.com/zclconf/go-cty from 1.13.2 to 1.14.0 by @dependabot in #1845
  • build(deps): Bump google.golang.org/grpc from 1.57.0 to 1.58.0 by @dependabot in #1848
  • Deprecate tflint-bundle image by @wata727 in #1837
  • build(deps): Bump google.golang.org/grpc from 1.58.0 to 1.58.1 by @dependabot in #1850
  • build(deps): Bump docker/build-push-action from 4 to 5 by @dependabot in #1851
  • build(deps): Bump docker/login-action from 2 to 3 by @dependabot in #1852
  • build(deps): Bump docker/setup-buildx-action from 2 to 3 by @dependabot in #1853
  • build(deps): Bump docker/metadata-action from 4 to 5 by @dependabot in #1854
  • build(deps): Bump goreleaser/goreleaser-action from 4 to 5 by @dependabot in #1855
  • build(deps): Bump mislav/bump-homebrew-formula-action from 2 to 3 by @dependabot in #1861
  • build(deps): Bump google.golang.org/grpc from 1.58.1 to 1.58.2 by @dependabot in #1862
  • build(deps): Bump github.com/spf13/afero from 1.9.5 to 1.10.0 by @dependabot in #1863
  • build(deps): Bump github.com/hashicorp/go-plugin from 1.5.1 to 1.5.2 by @dependabot in #1864
  • add test coverage for install script fail by @bendrucker in #1868
  • install: move -e out of shebang by @ddelange in #1870
  • build(deps): Bump golang.org/x/oauth2 from 0.12.0 to 0.13.0 by @dependabot in #1879
  • build(deps): Bump github.com/zclconf/go-cty from 1.14.0 to 1.14.1 by @dependabot in #1880
  • build(deps): Bump github.com/hashicorp/hcl/v2 from 2.18.0 to 2.18.1 by @dependabot in #1882
  • build(deps): Bump golang.org/x/net from 0.16.0 to 0.17.0 by @dependabot in #1884
  • build(deps): Bump github.com/hashicorp/hcl/v2 from 2.18.1 to 2.19.0 by @dependabot in #1885
  • build(deps): Bump google.golang.org/grpc from 1.58.2 to 1.58.3 by @dependabot in #1887
  • build(deps): Bump github.com/google/go-cmp from 0.5.9 to 0.6.0 by @dependabot in #1886
  • build(deps): Bump github.com/hashicorp/hcl/v2 from 2.19.0 to 2.19.1 by @dependabot in #1890
  • build(deps): Bump google.golang.org/grpc from 1.58.3 to 1.59.0 by @dependabot in #1891
  • build(deps): Bump github.com/google/uuid from 1.3.1 to 1.4.0 by @dependabot in #1898
  • build(deps): Bump github.com/fatih/color from 1.15.0 to 1.16.0 by @dependabot in #1905
  • build(deps): Bump golang.org/x/text from 0.13.0 to 0.14.0 by @dependabot in #1906

New Contributors

Full Changelog: v0.48.0...v0.49.0

v0.48.0

03 Sep 15:49
Compare
Choose a tag to compare

What's Changed

Breaking Changes

  • Bump tflint-plugin-sdk to v0.18.0 by @wata727 in #1813
    • This change causes the deprecated IncludeNotCreated option to be ignored. Most plugin users will not be affected.

BugFixes

  • langserver: Trap os.Interrupt and syscall.SIGTERM by @wata727 in #1809
  • Bump github.com/hashicorp/hcl to v2.18.0 by @wata727 in #1833
  • tflint: Allow commas with spaces in annotations by @wata727 in #1834

Chores

  • build(deps): Bump alpine from 3.18.0 to 3.18.2 by @dependabot in #1784
  • build(deps): Bump google.golang.org/grpc from 1.55.0 to 1.56.0 by @dependabot in #1785
  • build(deps): Bump golang.org/x/oauth2 from 0.8.0 to 0.9.0 by @dependabot in #1786
  • build(deps): Bump sigstore/cosign-installer from 3.0.5 to 3.1.0 by @dependabot in #1792
  • build(deps): Bump google.golang.org/grpc from 1.56.0 to 1.56.1 by @dependabot in #1793
  • build(deps): Bump sigstore/cosign-installer from 3.1.0 to 3.1.1 by @dependabot in #1798
  • Remove hard-coded versions from integration tests by @wata727 in #1799
  • build(deps): Bump golang.org/x/text from 0.10.0 to 0.11.0 by @dependabot in #1806
  • build(deps): Bump golang.org/x/crypto from 0.10.0 to 0.11.0 by @dependabot in #1804
  • build(deps): Bump golang.org/x/oauth2 from 0.9.0 to 0.10.0 by @dependabot in #1803
  • build(deps): Bump google.golang.org/grpc from 1.56.1 to 1.56.2 by @dependabot in #1805
  • Remove obsoleted PGP public key by @wata727 in #1800
  • Add make release for release automation by @wata727 in #1802
  • build(deps): Bump google.golang.org/grpc from 1.56.2 to 1.57.0 by @dependabot in #1815
  • build(deps): Bump golang.org/x/crypto from 0.11.0 to 0.12.0 by @dependabot in #1820
  • build(deps): Bump golang.org/x/text from 0.11.0 to 0.12.0 by @dependabot in #1821
  • build(deps): Bump golang.org/x/oauth2 from 0.10.0 to 0.11.0 by @dependabot in #1822
  • deps: upgrade to use go1.21 by @chenrui333 in #1823
  • build(deps): Bump github.com/google/uuid from 1.3.0 to 1.3.1 by @dependabot in #1829
  • build(deps): Bump golangci/golangci-lint-action from 3.6.0 to 3.7.0 by @dependabot in #1830

Full Changelog: v0.47.0...v0.48.0

v0.47.0

18 Jun 09:02
Compare
Choose a tag to compare

0.47.0 (2023-06-18)

This release introduces autofix feature. Running tflint --fix will automatically fix issues as possible. Note that not all rules support autofix. In order to support autofix, plugins must be built with SDK v0.17+ and implement autofix.

The bundled Terraform ruleset has been updated to v0.4.0 with autofix support. In other words, for Terraform rules, you can use autofix as it is. See the tflint-ruleset-terraform v0.4.0 changelog for details.

Breaking Changes

  • #1749: plugin: Drop support for plugin SDK v0.12/v0.13 (@wata727)
    • Plugins built using SDKs v0.12/v0.13 are no longer supported. If you get "SDK version is incompatible" error, you need to update the plugin to use SDK v0.14+.
  • #1750 #1781: Bump tflint-plugin-sdk and bundled terraform plugin
    • The SDK has been updated to v0.17.0 and the bundled Terraform plugin to v0.4.0. Terraform ruleset v0.3.0 contains breaking changes. Check the changelog for details.
  • #1779: cmd: Drop support for CLI arguments (@wata727)
    • Argument support has been removed based on the deprecation warning added in v0.46. As of v0.47, it returns an error instead of a warning. See #1687 for details.

Enhancements

  • #1751: plugin: support GitHub Enterprise Server as plugin source (@bendrucker)
  • #1755: Introduce autofix (@wata727)
  • #1773: build(deps): Bump github.com/hashicorp/hcl/v2 from 2.16.2 to 2.17.0
    • TFLint v0.47 host server return cty.Value now supports refinemnet. This is a change that only affects plugin developers. See HCL v2.17.0 changelog for details.
  • #1780: terraform: Add support for Terraform v1.5 (@wata727)
    • Added support for the planttimestamp and strcontains functions.

Chores

  • #1754 #1766: build(deps): Bump sigstore/cosign-installer from 3.0.2 to 3.0.5
  • #1759: build(deps): Bump google.golang.org/grpc from 1.54.0 to 1.55.0
  • #1762: build(deps): Bump alpine from 3.17.3 to 3.18.0
  • #1763: build(deps): Bump golang.org/x/oauth2 from 0.7.0 to 0.8.0
  • #1764: build(deps): Bump golang.org/x/crypto from 0.8.0 to 0.9.0
  • #1767: build(deps): Bump github.com/zclconf/go-cty from 1.13.1 to 1.13.2
  • #1771: fix(install_linux): Update unzip arguments (@alexjurkiewicz)
  • #1772 #1775: build(deps): Bump golangci/golangci-lint-action from 3.4.0 to 3.6.0
  • #1774: build(deps): Bump github.com/hashicorp/go-plugin from 1.4.9 to 1.4.10
  • #1776: build(deps): Bump golang.org/x/text from 0.9.0 to 0.10.0

v0.46.1

22 Apr 09:10
Compare
Choose a tag to compare

0.46.1 (2023-04-22)

BugFixes

Chores

  • #1738: build(deps): Bump sigstore/cosign-installer from 3.0.1 to 3.0.2
  • #1739: build(deps): Bump golang.org/x/crypto from 0.7.0 to 0.8.0
  • #1741: build(deps): Bump golang.org/x/oauth2 from 0.6.0 to 0.7.0
  • #1743: build(deps): Bump github.com/terraform-linters/tflint-plugin-sdk from 0.16.0 to 0.16.1