Sha256: c5b2169865aa989b0757a483ffaff527921c7fbd0bacc014050a2159e9c9c7bb

Contents?: true

Size: 601 Bytes

Versions: 96

Compression:

Stored size: 601 Bytes

Contents

module SpecInfra
  module Command
    class Plamo < Linux

      def check_enabled(service, level=3)
        # This check is not necessarily detected whether service is enabled or not
        # TODO: check rc.inet2 $SERV variable
        "test -x /etc/rc.d/init.d/#{escape(service)}"
      end

      def check_installed(package, version=nil)
        cmd = "ls /var/log/packages/#{escape(package)}"
        if version
          cmd = "#{cmd} && grep -E \"PACKAGE NAME:.+#{escape(package)}-#{escape(version)}\" /var/log/packages/#{escape(package)}"
        end
        cmd
      end

    end
  end
end

Version data entries

96 entries across 96 versions & 1 rubygems

Version Path
specinfra-1.27.5 lib/specinfra/command/plamo.rb
specinfra-1.27.4 lib/specinfra/command/plamo.rb
specinfra-1.27.3 lib/specinfra/command/plamo.rb
specinfra-1.27.2 lib/specinfra/command/plamo.rb
specinfra-1.27.1 lib/specinfra/command/plamo.rb
specinfra-1.27.0 lib/specinfra/command/plamo.rb
specinfra-1.26.0 lib/specinfra/command/plamo.rb
specinfra-1.25.8 lib/specinfra/command/plamo.rb
specinfra-1.25.7 lib/specinfra/command/plamo.rb
specinfra-1.25.6 lib/specinfra/command/plamo.rb
specinfra-1.25.5 lib/specinfra/command/plamo.rb
specinfra-1.25.4 lib/specinfra/command/plamo.rb
specinfra-1.25.3 lib/specinfra/command/plamo.rb
specinfra-1.25.2 lib/specinfra/command/plamo.rb
specinfra-1.25.1 lib/specinfra/command/plamo.rb
specinfra-1.25.0 lib/specinfra/command/plamo.rb
specinfra-1.24.0 lib/specinfra/command/plamo.rb
specinfra-1.23.1 lib/specinfra/command/plamo.rb
specinfra-1.23.0 lib/specinfra/command/plamo.rb
specinfra-1.22.1 lib/specinfra/command/plamo.rb