Created
August 18, 2014 23:47
-
-
Save petrhosek/3d42cc065a63f74250fd to your computer and use it in GitHub Desktop.
Reproducer for MissionCriticalCloud/vagrant-cloudstack#50
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#cloud-config | |
coreos: | |
units: | |
- name: etcd.service | |
command: start | |
- name: fleet.service | |
command: start | |
ssh_authorized_keys: | |
- ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEA6NF8iallvQVp22WDkTkyrtvp9eWW6A8YVr+kz4TjGYe7gHzIw+niNltGEFHzD8+v1I2YJ6oXevct1YeS0o9HZyN1Q9qgCgzUFtdOKLv6IedplqoPkcmF0aYet2PkEDo3MlTBckFXPITAMzF8dJSIFo9D8HfdOV0IAdx4O7PtixWKn5y2hMNG0zQPyUecp4pzC6kivAIhyfHilFR61RGL+GPXQ2MWZWFYbAGjyiYJnAmCP3NOTd0jMZEnDkbUvxhMmBYSdETk1rRgm+R4LOzFUGaHqHDLKLX+FIPKcF96hrucXzcWyLbIbEgE98OHlnVYCzRdK8jlqm8tehUc9c9WhQ== vagrant insecure public key |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"variables": { | |
"channel": "alpha", | |
"base_url": "http://alpha.release.core-os.net/amd64-usr/current" | |
}, | |
"builders": [ | |
{ | |
"name": "coreos-{{ user `channel` }}", | |
"type": "cloudstack", | |
"http_directory": "http", | |
"insecure_skip_verify": true, | |
"ssh_username": "core", | |
"ssh_key_path": "/home/petr/.vagrant.d/insecure_private_key", | |
"ssh_timeout": "20m", | |
"service_offering_id": "6d633462-d76c-47a7-93d6-436516acc486", | |
"template_id": "a55a0782-4bb6-4467-86cf-ae3b84dfc7cf", | |
"template_os_id": "7d9de210-1fa2-11e3-809d-38acb5898e2d", | |
"zone_id": "ec3bf9da-f510-49a0-b21d-fb7ecdd5ab67", | |
"disk_offering_id": "45fa18b3-bf31-4927-8ac5-2e397949f1c5", | |
"user_data": "#!ipxe\nkernel {{ user `base_url` }}/coreos_production_pxe.vmlinuz cloud-config-url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/cloud-config.yaml\ninitrd {{ user `base_url` }}/coreos_production_pxe_image.cpio.gz\nboot", | |
"hypervisor": "XenServer" | |
} | |
], | |
"provisioners": [ | |
{ | |
"type": "shell", | |
"inline": ["sudo coreos-install -d /dev/xvda -C {{ user `channel` }} -o cloudstack"] | |
} | |
], | |
"post-processors": [ | |
{ | |
"type": "vagrant" | |
} | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#cloud-config | |
coreos: | |
etcd: | |
discovery: https://discovery.etcd.io/<id> | |
addr: $public_ipv4:4001 | |
peer-addr: $public_ipv4:7001 | |
units: | |
- name: etcd.service | |
command: start | |
- name: fleet.service | |
command: start |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
VAGRANTFILE_API_VERSION = "2" | |
CLOUD_CONFIG_PATH = "./user-data" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | |
config.vm.box = "packer_coreos-alpha_cloudstack" | |
config.ssh.username = "core" | |
config.ssh.private_key_path = "~/.ssh/id_rsa.vagrant" | |
config.vm.provider :cloudstack do |cloudstack| | |
cloudstack.service_offering_id = "6d633462-d76c-47a7-93d6-436516acc486" | |
cloudstack.zone_id = "ec3bf9da-f510-49a0-b21d-fb7ecdd5ab67" | |
cloudstack.network_type = "Basic" | |
cloudstack.keypair = "vagrant" | |
if File.exist?(CLOUD_CONFIG_PATH) | |
cloudstack.user_data = File.read(CLOUD_CONFIG_PATH) | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment