Skip to content
Snippets Groups Projects
Commit 7509f5c0 authored by Craig Miskell's avatar Craig Miskell
Browse files

fix: Use chdir for tflint 0.47.0

Specifying a path on the command line was deprecated, and as of tflint 0.47.0
is removed and replaced by --chdir or --filter

The simple solution is to continue using . but with --chdir instead.
parent bfd4fc34
No related branches found
No related tags found
No related merge requests found
Pipeline #16941058 passed
Loading
Loading
@@ -21,8 +21,8 @@ tflint:
echo "${dir} -------------------------------------------------------";
cd "${CI_PROJECT_DIR}/${dir}" || exit 1;
terraform init -backend=false -reconfigure;
tflint -c "${CI_PROJECT_DIR}/.tflint.hcl" . -f compact || echo "${dir}" >> "${CI_PROJECT_DIR}/tflint-reports/failed";
tflint -c "${CI_PROJECT_DIR}/.tflint.hcl" . -f junit > "${CI_PROJECT_DIR}/tflint-reports/${junit_file}";
tflint -c "${CI_PROJECT_DIR}/.tflint.hcl" --chdir=. -f compact || echo "${dir}" >> "${CI_PROJECT_DIR}/tflint-reports/failed";
tflint -c "${CI_PROJECT_DIR}/.tflint.hcl" --chdir=. -f junit > "${CI_PROJECT_DIR}/tflint-reports/${junit_file}";
done;
# tflint-reports/failed indicates a linter failure
- if [ -f "${CI_PROJECT_DIR}/tflint-reports/failed" ]; then
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment