lib/vagrant/util/guest_inspection.rb in vagrant-unbundled-2.2.7.0 vs lib/vagrant/util/guest_inspection.rb in vagrant-unbundled-2.2.8.0
- old
+ new
@@ -10,11 +10,11 @@
# systemd is in use
#
# @return [Boolean]
def systemd?(comm)
- comm.test("ps -o comm= 1 | grep systemd")
+ comm.test("ps -o comm= 1 | grep systemd", sudo: true)
end
# systemd-networkd.service is in use
#
# @param [Vagrant::Plugin::V2::Communicator] comm Guest communicator
@@ -69,9 +69,17 @@
#
# @param [Vagrant::Plugin::V2::Communicator] comm Guest communicator
# @return [Boolean]
def netplan?(comm)
comm.test("command -v netplan")
+ end
+
+ # is networkd isntalled
+ #
+ # @param [Vagrant::Plugin::V2::Communicator] comm Guest communicator
+ # @return [Boolean]
+ def networkd?(comm)
+ comm.test("command -v networkd")
end
## nmcli helpers
# nmcli is installed