mirror of
https://github.com/clearlinux/cloud-native-setup.git
synced 2026-08-18 21:16:16 +00:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 24f248b02f | |||
| d688cbb693 |
Vendored
+6
-1
@@ -13,7 +13,7 @@ $disks = 2
|
||||
$disk_prefix = File.basename(File.dirname(__FILE__), "/")
|
||||
$disk_size = "10G"
|
||||
$box = "AntonioMeireles/ClearLinux"
|
||||
$loader = File.join(File.dirname(__FILE__), "OVMF.fd")
|
||||
File.exists?("/usr/share/qemu/OVMF.fd") ? $loader = "/usr/share/qemu/OVMF.fd" : $loader = File.join(File.dirname(__FILE__), "OVMF.fd")
|
||||
$vm_name_prefix = "clr"
|
||||
$base_ip = IPAddr.new("192.52.100.10")
|
||||
$hosts = {}
|
||||
@@ -21,6 +21,10 @@ $proxy_ip_list = ""
|
||||
$driveletters = ('a'..'z').to_a
|
||||
$setup_fc = true ? (['true', '1'].include? ENV['SETUP_FC'].to_s) : false
|
||||
|
||||
if not File.exists?($loader)
|
||||
system('curl -O https://download.clearlinux.org/image/OVMF.fd')
|
||||
end
|
||||
|
||||
# We need v 1.0.14 or above for this vagrantfile to work.
|
||||
unless Vagrant.has_plugin?("vagrant-guests-clearlinux")
|
||||
system "vagrant plugin install vagrant-guests-clearlinux"
|
||||
@@ -61,6 +65,7 @@ Vagrant.configure("2") do |config|
|
||||
c.vm.provider :libvirt do |lv|
|
||||
lv.cpu_mode = "host-passthrough"
|
||||
lv.nested = true
|
||||
lv.loader = $loader
|
||||
lv.cpus = $cpus
|
||||
lv.memory = $memory
|
||||
(1..$disks).each do |d|
|
||||
|
||||
@@ -22,6 +22,7 @@ fi
|
||||
sudo mkdir -p /etc/sysctl.d/
|
||||
cat <<EOT | sudo bash -c "cat > /etc/sysctl.d/60-k8s.conf"
|
||||
net.ipv4.ip_forward=1
|
||||
net.ipv4.conf.default.rp_filter=1
|
||||
EOT
|
||||
sudo systemctl restart systemd-sysctl
|
||||
|
||||
|
||||
Reference in New Issue
Block a user