X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=packer%2Fold_releases%2Fubuntu1604-ovf-osm.json;fp=packer%2Fold_releases%2Fubuntu1604-ovf-osm.json;h=c2071a9a079ac29555e7a24aa607c3bb3d8a052e;hb=8ac0f088f6d30ee030f1ef6fe768da2f242c5046;hp=0000000000000000000000000000000000000000;hpb=4b57d46af8be1804faffa27a987e614c45056147;p=osm%2Fdevops.git diff --git a/packer/old_releases/ubuntu1604-ovf-osm.json b/packer/old_releases/ubuntu1604-ovf-osm.json new file mode 100644 index 00000000..c2071a9a --- /dev/null +++ b/packer/old_releases/ubuntu1604-ovf-osm.json @@ -0,0 +1,69 @@ +{ + "provisioners": [ + { + "type": "shell", + "script": "scripts/get-install-osm.sh", + "execute_command": "{{.Path}} {{user `osm_install_options`}}" + }, + { + "type": "shell", + "execute_command": "echo 'vagrant' | {{.Vars}} sudo -S -E bash '{{.Path}}'", + "script": "scripts/vimemu.sh" + }, + { + "type": "shell", + "execute_command": "echo 'vagrant' | {{.Vars}} sudo -S -E bash '{{.Path}}'", + "script": "scripts/cleanup.sh" + } + ], + "variables": { + "osm_install_options": "--vimemu", + "input_ovf": "output-virtualbox-iso/packer-ubuntu-16.04-amd64-juju.ovf", + "vm_name": "xenial-osm", + "build_dir": "osm-{{timestamp}}" + }, + "builders": [ + { + "type": "virtualbox-ovf", + "source_path": "{{user `input_ovf`}}", + "headless": true, + "ssh_username": "vagrant", + "ssh_password": "vagrant", + "ssh_port": 22, + "ssh_wait_timeout": "10000s", + "shutdown_command": "echo '/sbin/shutdown -h -P now' > /tmp/shutdown.sh; echo 'vagrant'|sudo -S sh '/tmp/shutdown.sh'", + "virtualbox_version_file": ".vbox_version", + "vm_name": "{{user `vm_name`}}", + "output_directory": "{{user `build_dir`}}", + "vboxmanage": [ + [ + "modifyvm", + "{{.Name}}", + "--memory", + "4096" + ], + [ + "modifyvm", + "{{.Name}}", + "--cpus", + "2" + ] + ] + } + ], + "post-processors": [ + [ + { + "output": "{{user `build_dir`}}/{{.Provider}}-osm.box", + "type": "vagrant", + "keep_input_artifact": true + }, + { + "type": "vagrant-cloud", + "box_tag": "osm/{{user `release`}}", + "access_token": "{{user `cloud_token`}}", + "version": "{{user `version`}}" + } + ] + ] +}