packer-cn/test/fixtures/builder-lxc/minimal.json

32 lines
918 B
JSON
Raw Normal View History

2016-05-25 17:23:07 -04:00
{
"variables": {
"template_name": "debian",
"template_parameters": "SUITE=jessie",
"container_name": "packer-lxc",
"set_var": "hello"
2016-05-25 17:23:07 -04:00
},
"provisioners": [
{
"type": "shell",
"inline": [
"if [ \"$SET_VAR\" != \"{{user `set_var`}}\" ]; then",
" echo \"Got unexpected value '$SET_VAR' for SET_VAR\" 1>&2",
" exit 1",
"fi"
]
}
],
2016-05-25 17:23:07 -04:00
"builders": [
{
"type": "lxc",
"name": "lxc-{{user `template_name`}}",
"template_name": "{{user `template_name`}}",
"container_name": "{{user `container_name`}}",
"create_options": [ "-f", "{{user `init_config`}}" ],
"attach_options": [ "--clear-env", "--set-var", "SET_VAR={{user `set_var`}}" ],
2016-05-25 17:23:07 -04:00
"config_file": "/usr/share/lxc/config/{{user `template_name`}}.common.conf",
"template_environment_vars": [ "{{user `template_parameters`}}" ]
}
]
}