From 9089750277891204219b769e67093b85705325f3 Mon Sep 17 00:00:00 2001 From: Hans-Christoph Steiner Date: Wed, 18 May 2022 21:20:25 +0200 Subject: [PATCH] buildserver: show informative message if Vagrant is not configed --- buildserver/Vagrantfile | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/buildserver/Vagrantfile b/buildserver/Vagrantfile index 57509ffe..89ab1940 100644 --- a/buildserver/Vagrantfile +++ b/buildserver/Vagrantfile @@ -2,7 +2,13 @@ require 'yaml' require 'pathname' srvpath = Pathname.new(File.dirname(__FILE__)).realpath -configfile = YAML.load_file(File.join(srvpath, "/Vagrantfile.yaml")) +configpath = File.join(srvpath, "/Vagrantfile.yaml") +if File.exists? configpath + configfile = YAML.load_file(configpath) +else + puts "#{configpath} does not exist, run ./makebuildserver?" + configfile = Hash.new +end Vagrant.configure("2") do |config|