8
8

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

[Vagrant 1.5] vagrant provisionしたら、SSL validation of HTTPS requests is disabled とエラーがでたら。

Last updated at Posted at 2014-07-23

エラー

vagrant provisionをしたしたところ、以下のエラーが出ました。

SSL validation of HTTPS requests is disabled. HTTPS connections are still
encrypted, but chef is not able to detect forged replies or man in the middle
attacks.

To fix this issue add an entry like this to your configuration file:

  # Verify all HTTPS connections (recommended)
  ssl_verify_mode :verify_peer

  # OR, Verify only connections to chef-server
  verify_api_cert true

この通りに対応すれば直りますが、私にはよくわからなかったので調べてみました。

対応

とりあえず、Vagrantfileをいじります。

Vagrant.configure("2") do |config|
  config.vm.provision "chef_solo" do |chef|
   ・
   ・
    # 以下を追加
    chef.custom_config_path = "Vagrantfile.chef"
   ・
   ・
  end
end

次に、Vagrantfileと同じ階層
にVagrantfile.chefというファイルを作成します。

$ vim Vagrantfile.chef
----

#以下を記述
Chef::Config.ssl_verify_mode = :verify_peer

その後

$ vagrant reload
$ vagrant provision

で解決しました。

参考

8
8
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
8
8

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?