Class: Landrush::Cap::Ubuntu::UbuntuHost

Inherits:
Object
  • Object
show all
Defined in:
lib/landrush/cap/host/ubuntu/host.rb

Instance Method Summary collapse

Instance Method Details

#detect?(_env) ⇒ Boolean

Returns:

  • (Boolean)


5
6
7
8
# File 'lib/landrush/cap/host/ubuntu/host.rb', line 5

def detect?(_env)
  return false unless Pathname('/usr/bin/lsb_release').exist?
  system("/usr/bin/lsb_release -i | grep 'Ubuntu' >/dev/null 2>&1")
end