plugins/provisioners/docker/config.rb in vagrant-unbundled-1.9.5.1 vs plugins/provisioners/docker/config.rb in vagrant-unbundled-1.9.7.1

- old
+ new

@@ -2,13 +2,15 @@ module VagrantPlugins module DockerProvisioner class Config < Vagrant.plugin("2", :config) attr_reader :images + attr_accessor :post_install_provisioner def initialize @images = Set.new + @post_install_provisioner = nil @__build_images = [] @__containers = Hash.new { |h, k| h[k] = {} } end @@ -34,9 +36,18 @@ @images = Set.new(images) end def pull_images(*images) @images += images.map(&:to_s) + end + + def post_install_provision(name, **options, &block) + # Abort + raise DockerError, :wrong_provisioner if options[:type] == "docker" + + proxy = VagrantPlugins::Kernel_V2::VMConfig.new + proxy.provision(name, **options, &block) + @post_install_provisioner = proxy.provisioners.first end def run(name, **options) @__containers[name.to_s] = options.dup end