From f7aec1c86765a5f05c675be86f9b268b19bb047a Mon Sep 17 00:00:00 2001 From: Georg Pfuetzenreuter Date: Thu, 8 Jun 2023 14:55:26 +0200 Subject: [PATCH] Only restart network once One restart of the network restart is needed to get Avahi DNS resolution to work, however restarts on subsequent --refresh runs are wasting time. Signed-off-by: Georg Pfuetzenreuter --- Vagrantfile-Template | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Vagrantfile-Template b/Vagrantfile-Template index 8139228..55db829 100644 --- a/Vagrantfile-Template +++ b/Vagrantfile-Template @@ -14,7 +14,11 @@ Vagrant.configure("2") do |config| config.vm.box = ENV['SCULLERY_BOX_NAME'] config.vm.box_url = ENV['SCULLERY_BOX_IMAGE'] config.vm.provision "shell", inline: <<-SHELL - systemctl restart network + if [ ! -f '/var/adm/scullery.configured' ] + then + systemctl restart network + touch /var/adm/scullery.configured + fi SHELL if ENV['SCULLERY_MASTERS'] ENV['SCULLERY_MASTERS'].split(',').each do |vmname|