kitchen terraform error - Could not load the 'terraform' driver. Error: undefined method `size' for nil:NilClass

kitchen terraform error - Could not load the 'terraform' driver. Error: undefined method `size' for nil:NilClass

我正在关注 https://newcontext-oss.github.io/kitchen-terraform/getting_started.html 但是,当我尝试 运行 时: bundle exec kitchen converge

我收到以下错误:

>>>>>> ------Exception-------
>>>>>> Class: Kitchen::ClientError
>>>>>> Message: Could not load the 'terraform' driver. Error: undefined method `size' for nil:NilClass
>>>>>> ----------------------
>>>>>> Please see .kitchen/logs/kitchen.log for more details
>>>>>> Also try running `kitchen diagnose --all` for configuration

有什么想法吗? 运行TF 1.0.7

我按照官方教程也有这个bug

我通过更新 Gemfile 以使用最新版本的 kitchen-terraform

解决了这个问题
# Gemfile

source "https://rubygems.org/"
gem "kitchen-terraform", "6.0"

如果它解决了您的问题,请告诉我!