From fedc7e21b3d3b61e3a2bc7b085d0de494ad8ac71 Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Wed, 18 Nov 2015 11:56:07 -0800 Subject: [PATCH] provisioners/salt: deprecate config_dir --- CHANGELOG.md | 4 +++- plugins/provisioners/salt/config.rb | 4 ++++ test/unit/plugins/provisioners/salt/config_test.rb | 6 ++++++ 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c85b65ffe..c3cfb09a4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,13 +15,15 @@ FEATURES: BREAKING CHANGES: - - the `ansible` provisioner now can override the effective ansible remote user + - The `ansible` provisioner now can override the effective ansible remote user (i.e. `ansible_ssh_user` setting) to always correspond to the vagrant ssh username. This change is enabled by default, but we expect this to affect only a tiny number of people as it corresponds to the common usage. If you however use multiple remote usernames in your Ansible plays, tasks, or custom inventories, you can simply set the option `force_remote_user` to false to make Vagrant behave the same as before. + - provisioners/salt: the "config_dir" option has been removed. It has no + effect in Vagrant 1.8. [GH-6073] IMPROVEMENTS: diff --git a/plugins/provisioners/salt/config.rb b/plugins/provisioners/salt/config.rb index 38aaec8de..4bf342d45 100644 --- a/plugins/provisioners/salt/config.rb +++ b/plugins/provisioners/salt/config.rb @@ -4,6 +4,10 @@ require "vagrant/util/deep_merge" module VagrantPlugins module Salt class Config < Vagrant.plugin("2", :config) + ## @deprecated + def config_dir=(value) + puts "salt config_dir is deprecated and will be removed in Vagrant 1.9" + end ## salty-vagrant options attr_accessor :minion_config diff --git a/test/unit/plugins/provisioners/salt/config_test.rb b/test/unit/plugins/provisioners/salt/config_test.rb index 24bf24796..92e935db0 100644 --- a/test/unit/plugins/provisioners/salt/config_test.rb +++ b/test/unit/plugins/provisioners/salt/config_test.rb @@ -16,6 +16,12 @@ describe VagrantPlugins::Salt::Config do let(:machine) { iso_env.machine(iso_env.machine_names[0], :dummy) } + describe "#config_dir" do + it "is deprecated until Vagrant 1.9" do + raise "Remove the deprecation" if Vagrant::VERSION >= "1.9.0" + end + end + describe "validate" do let(:error_key) { "salt provisioner" }