summaryrefslogtreecommitdiff
path: root/puppet/modules/site_config/lib
diff options
context:
space:
mode:
authorkwadronaut <kwadronaut@leap.se>2017-05-23 16:20:26 +0200
committerkwadronaut <kwadronaut@leap.se>2017-05-23 16:20:55 +0200
commit0e09968d8ed3f245a238306de43a037d0749fd5a (patch)
tree165d49dfb17d115dbb649ffe669064f2042bb527 /puppet/modules/site_config/lib
parent26be1f84de9efabf5fec1278401ae0c5538454d9 (diff)
parent40f7b49003594a1be8c0540a92292d7cfb63eb61 (diff)
Merge branch 'varac/platform-vagrant_private_networking'
Diffstat (limited to 'puppet/modules/site_config/lib')
-rw-r--r--puppet/modules/site_config/lib/facter/vagrant.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/puppet/modules/site_config/lib/facter/vagrant.rb b/puppet/modules/site_config/lib/facter/vagrant.rb
new file mode 100644
index 00000000..29a218dd
--- /dev/null
+++ b/puppet/modules/site_config/lib/facter/vagrant.rb
@@ -0,0 +1,8 @@
+# Checks if systems runs inside vagrant
+require 'facter'
+
+Facter.add(:vagrant) do
+ setcode do
+ FileTest.exists?('/vagrant')
+ end
+end