-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This hasn't landed upstream yet in Vagrant, but this just anticipates it existing in the future.
- Loading branch information
Showing
2 changed files
with
49 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
module VagrantPlugins | ||
module GuestAlma | ||
module Cap | ||
class SSHFSClient | ||
def self.sshfs_install(machine) | ||
|
||
case machine.guest.capability("flavor") | ||
when :alma_8 | ||
# No need to install epel. fuse-sshfs comes from the powertools repo | ||
# https://bugzilla.redhat.com/show_bug.cgi?id=1758884 | ||
# https://github.com/dustymabe/vagrant-sshfs/issues/123 | ||
machine.communicate.sudo("yum -y install --enablerepo=powertools fuse-sshfs") | ||
when :alma_9, :alma # alma9 or unknown | ||
# Install fuse-sshfs from epel | ||
if !epel_installed(machine) | ||
epel_install(machine) | ||
end | ||
machine.communicate.sudo("yum -y install fuse-sshfs") | ||
end | ||
end | ||
|
||
def self.sshfs_installed(machine) | ||
machine.communicate.test("rpm -q fuse-sshfs") | ||
end | ||
|
||
protected | ||
|
||
def self.epel_installed(machine) | ||
machine.communicate.test("rpm -q epel-release") | ||
end | ||
|
||
def self.epel_install(machine) | ||
machine.communicate.sudo("yum -y install epel-release") | ||
end | ||
|
||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters