Sha256: 63e520be63e5159dcba72dfc659d9b63b22744c4530ccff5cf9e44481a77765e

Contents?: true

Size: 592 Bytes

Versions: 4

Compression:

Stored size: 592 Bytes

Contents

module Vagrant
  module Plugin
    module Remote
      # This class enables Push for server mode
      class Push < V2::Push
        # Add an attribute accesor for the client
        # when applied to the Push class
        attr_accessor :client

        def initialize(env, config, **opts)
          if opts[:client].nil?
            raise ArgumentError,
              "Remote client is required for `#{self.class.name}`"
          end
          @client = opts[:client]
          super(env, config)
        end

        def push
          client.push
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
vagrant-unbundled-2.3.6.0 lib/vagrant/plugin/remote/push.rb
tamtam-vagrant-reload-1.2.1 vendor/cache/vagrant-2092df529ae7/lib/vagrant/plugin/remote/push.rb
vagrant-unbundled-2.3.3.0 lib/vagrant/plugin/remote/push.rb
vagrant-unbundled-2.3.2.0 lib/vagrant/plugin/remote/push.rb