Sha256: 2f0ac7c7fe05d224ab67a1688232a8d52114522fcd5941103a91a7e89e2c5ab9

Contents?: true

Size: 702 Bytes

Versions: 1

Compression:

Stored size: 702 Bytes

Contents

module VagrantPlugins
  module CommunicatorWinRM
    module CommandFilters
      # Handles the special case of determining the guest OS using cat
      class Cat
        def filter(command)
          # cat /etc/release | grep -i OmniOS
          # cat /etc/redhat-release
          # cat /etc/issue | grep 'Core Linux'
          # cat /etc/release | grep -i SmartOS
          ''
        end

        def accept?(command)
          # cat works in PowerShell, however we don't want to run Guest
          # OS detection as this will fail on Windows because the lack of the
          # grep command
          command.start_with?('cat /etc/')
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
vagrant-cloudstack-1.2.0 vendor/bundle/bundler/gems/vagrant-c84e05fd063f/plugins/communicators/winrm/command_filters/cat.rb