This repository was archived by the owner on Oct 24, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 20
Expand file tree
/
Copy pathpackerfile.json
More file actions
83 lines (83 loc) · 2.3 KB
/
packerfile.json
File metadata and controls
83 lines (83 loc) · 2.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
{
"variables": {
"variable2": "",
"variable1": "",
"aws_access_key": "{{env `AWS_ACCESS_KEY_ID`}}",
"aws_secret_key": "{{env `AWS_ACCESS_KEY`}}",
"aws_source_ami": "",
"instance_type": "m3.large",
"virtualbox_source_image": "",
"insecure_private_key": "./keys/insecure_private_key"
},
"builders": [
{
"name": "virtualbox",
"type": "virtualbox-ovf",
"source_path": "{{user `virtualbox_source_image`}}",
"vm_name": "cloudify",
"ssh_username": "vagrant",
"ssh_key_path": "{{user `insecure_private_key`}}",
"ssh_wait_timeout": "2m",
"shutdown_command": "sudo -S shutdown -P now",
"vboxmanage": [
["modifyvm", "{{.Name}}", "--memory", "2048"],
["modifyvm", "{{.Name}}", "--cpus", "2"],
["modifyvm", "{{.Name}}", "--natdnshostresolver1", "on"]
],
"headless": true
},
{
"name": "nightly_virtualbox_build",
"type": "amazon-ebs",
"access_key": "{{user `aws_access_key`}}",
"secret_key": "{{user `aws_secret_key`}}",
"ssh_private_key_file": "{{user `insecure_private_key`}}",
"region": "eu-west-1",
"source_ami": "{{user `aws_source_ami`}}",
"instance_type": "{{user `instance_type`}}",
"ssh_username": "vagrant",
"user_data_file": "userdata/add_vagrant_user.sh",
"ami_name": "cloudify nightly {{timestamp}}"
},
{
"name": "amazon",
"type": "amazon-ebs",
"access_key": "{{user `aws_access_key`}}",
"secret_key": "{{user `aws_secret_key`}}",
"region": "eu-west-1",
"source_ami": "{{user `aws_source_ami`}}",
"instance_type": "{{user `instance_type`}}",
"ssh_username": "ubuntu",
"ami_name": "cloudify {{timestamp}}"
}
],
"provisioners": [
{
"type": "shell",
"script": "provision/common.sh"
},
{
"type": "shell",
"script": "provision/prepare_nightly.sh",
"only": ["nightly_virtualbox_build"]
},
{
"type": "shell",
"script": "provision/cleanup.sh",
"only": ["nightly_virtualbox_build"]
}
],
"post-processors": [
{
"type": "vagrant",
"only": ["virtualbox"],
"output": "cloudify_{{.Provider}}.box"
}
],
"post-processors": [
{
"type": "compress",
"format": "tar.gz"
}
]
}