summaryrefslogtreecommitdiff
path: root/global/overlay/etc/puppet/modules/sunet/manifests/cloudimage.pp
diff options
context:
space:
mode:
Diffstat (limited to 'global/overlay/etc/puppet/modules/sunet/manifests/cloudimage.pp')
-rw-r--r--global/overlay/etc/puppet/modules/sunet/manifests/cloudimage.pp38
1 files changed, 0 insertions, 38 deletions
diff --git a/global/overlay/etc/puppet/modules/sunet/manifests/cloudimage.pp b/global/overlay/etc/puppet/modules/sunet/manifests/cloudimage.pp
deleted file mode 100644
index d6400d7..0000000
--- a/global/overlay/etc/puppet/modules/sunet/manifests/cloudimage.pp
+++ /dev/null
@@ -1,38 +0,0 @@
-define sunet::cloudimage (
- $image_url = "https://cloud-images.ubuntu.com/trusty/current/trusty-server-cloudimg-amd64-disk1.img",
- $dhcp = true,
- $size = "1G",
- $bridge = "br0",
- $memory = "1024",
- $cpus = "1",
- $resolver = undef,
- $ip = undef,
- $netmask = undef,
- $gateway = undef,
- $ip6 = undef,
- $netmask6 = "64",
- $gateway6 = undef,
- $tagpattern = undef,
- $repo = undef
-)
-{
- package {'mtools': ensure => latest }
- package {'libvirt-bin': ensure => latest }
- package {'uuid-runtime': ensure => latest }
- package {'virtinst': ensure => latest }
-
- $image_url_a = split($image_url,"/")
- $image_name = $image_url_a[-1]
- $image_src = "/var/lib/libvirt/images/${image_name}"
- file { "/var/lib/libvirt/images/${name}": ensure => directory } ->
- exec {"wget -O${image_src} ${image_url}":
- onlyif => "test ! -f ${image_src}"
- }
- file { "/var/lib/libvirt/images/${name}/${name}-init.sh":
- content => template("sunet/cloudimage/mk_cloud_image.erb"),
- mode => "0755"
- } ->
- exec { "/var/lib/libvirt/images/${name}/${name}-init.sh":
- onlyif => "test ! -f /var/lib/libvirt/images/${name}/${name}.img"
- }
-}