From 07e38f1bb3e890fa373fda3e106f08e69c7194a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Guillermo=20Bonveh=C3=AD?= Date: Wed, 7 Oct 2015 01:17:07 -0300 Subject: [PATCH] Fix Slackware Host detection and nfsd checks Slackware's version file is /etc/slackware-version not /etc/slackware-release. pidof is not on PATH by default (not running as root) so call it using full path --- plugins/hosts/slackware/cap/nfs.rb | 2 +- plugins/hosts/slackware/host.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/hosts/slackware/cap/nfs.rb b/plugins/hosts/slackware/cap/nfs.rb index e7f21a094..84413236d 100644 --- a/plugins/hosts/slackware/cap/nfs.rb +++ b/plugins/hosts/slackware/cap/nfs.rb @@ -3,7 +3,7 @@ module VagrantPlugins module Cap class NFS def self.nfs_check_command(env) - "pidof nfsd >/dev/null" + "/sbin/pidof nfsd >/dev/null" end def self.nfs_start_command(env) diff --git a/plugins/hosts/slackware/host.rb b/plugins/hosts/slackware/host.rb index 2afaff8f3..ec3503ac0 100644 --- a/plugins/hosts/slackware/host.rb +++ b/plugins/hosts/slackware/host.rb @@ -4,7 +4,7 @@ module VagrantPlugins module HostSlackware class Host < Vagrant.plugin("2", :host) def detect?(env) - return File.exists?("/etc/slackware-release") || + return File.exists?("/etc/slackware-version") || !Dir.glob("/usr/lib/setup/Plamo-*").empty? end end