Open GeFrIt42 opened 10 months ago
after digging, NixOs uses systemd, Vagrant supposed to detect if the platform uses systemd or sysV https://github.com/hashicorp/vagrant/blob/9b460ecedefa45a557b1c13c63449839819dc220/plugins/hosts/linux/cap/nfs.rb
if Vagrant::Util::Platform.systemd?
"systemctl status --no-pager #{nfs_service_name_systemd}"
else
"/etc/init.d/#{nfs_service_name_sysv} status"
end
inspiring myself from a old issue #1125 I have created a /etc/init.d/nfs-kernel-server with execution permission
#!/bin/sh
echo $@ >> /home/<your usename>/vagrant.log
it turned out that vagrant try execute /etc/init.d/nfs-kernel-server once with the parameter status on vagrant up
and vagrant reload
, despite that folders seems to be mounted and working normally.
this seems working for now as workaround though very ugly.
Debug output
https://gist.github.com/GeFrIt42/8a808adbc607c9c370113a6413a7c03b
Expected behavior
founder should be mounted via nfs. this was working 6 month ago.
Actual behavior
INFO interface: error: The executable '/etc/init.d/nfs-kernel-server' Vagrant is trying to run was not found in the PATH variable. This is an error. Please verify this software is installed and on the path. The executable '/etc/init.d/nfs-kernel-server' Vagrant is trying to run was not found in the PATH variable. This is an error. Please verify this software is installed and on the path. INFO interface: Machine: error-exit ["Vagrant::Errors::CommandUnavailable", "The executable '/etc/init.d/nfs-kernel-server' Vagrant is trying to run was not\nfound in the PATH variable. This is an error. Please verify\nthis software is installed and on the path."]
Reproduction information
Vagrant version
Vagrant 2.3.4 vagrant-libvirt (0.8.2, system)
Host operating system
Distributor ID: NixOS Description: NixOS 23.11 (Tapir) Release: 23.11 Codename: tapir
Guest operating system
config.vm.box = "generic/ubuntu2204"
Steps to reproduce
Vagrantfile
extra info
nfs server is running, configured accordingly https://nixos.wiki/wiki/Vagrant this mount was actually working 6 months ago.