mirror of
https://github.com/kevingruesser/bootstrap-vz.git
synced 2025-08-24 15:36:27 +00:00
Convert "provider" into provider specific section
This is where all provider specific settings belong like waagent on azure, guest additions iso path on vbox and virtualization type on ec2
This commit is contained in:
parent
5bb0e5428e
commit
ebba39f59b
37 changed files with 234 additions and 183 deletions
|
@ -4,7 +4,11 @@
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"provider": {
|
"provider": {
|
||||||
"type": "string"
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"name": { "type": "string" }
|
||||||
|
},
|
||||||
|
"required": ["name"]
|
||||||
},
|
},
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
|
|
|
@ -39,7 +39,7 @@ class Manifest(object):
|
||||||
self.data = load_yaml(self.path)
|
self.data = load_yaml(self.path)
|
||||||
|
|
||||||
# Get the provider name from the manifest and load the corresponding module
|
# Get the provider name from the manifest and load the corresponding module
|
||||||
provider_modname = 'bootstrapvz.providers.' + self.data['provider']
|
provider_modname = 'bootstrapvz.providers.' + self.data['provider']['name']
|
||||||
log.debug('Loading provider ' + provider_modname)
|
log.debug('Loading provider ' + provider_modname)
|
||||||
# Create a modules dict that contains the loaded provider and plugins
|
# Create a modules dict that contains the loaded provider and plugins
|
||||||
import importlib
|
import importlib
|
||||||
|
|
|
@ -63,10 +63,10 @@ class SetMetadataSource(Task):
|
||||||
sources = info.manifest.plugins['cloud_init']['metadata_sources']
|
sources = info.manifest.plugins['cloud_init']['metadata_sources']
|
||||||
else:
|
else:
|
||||||
source_mapping = {'ec2': 'Ec2'}
|
source_mapping = {'ec2': 'Ec2'}
|
||||||
sources = source_mapping.get(info.manifest.provider, None)
|
sources = source_mapping.get(info.manifest.provider['name'], None)
|
||||||
if sources is None:
|
if sources is None:
|
||||||
msg = ('No cloud-init metadata source mapping found for provider `{provider}\', '
|
msg = ('No cloud-init metadata source mapping found for provider `{provider}\', '
|
||||||
'skipping selections setting.').format(provider=info.manifest.provider)
|
'skipping selections setting.').format(provider=info.manifest.provider['name'])
|
||||||
logging.getLogger(__name__).warn(msg)
|
logging.getLogger(__name__).warn(msg)
|
||||||
return
|
return
|
||||||
sources = "cloud-init cloud-init/datasources multiselect " + sources
|
sources = "cloud-init cloud-init/datasources multiselect " + sources
|
||||||
|
|
|
@ -3,13 +3,9 @@
|
||||||
"title": "Azure manifest",
|
"title": "Azure manifest",
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"system": {
|
"provider": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"bootloader": {
|
|
||||||
"type": "string",
|
|
||||||
"enum": ["grub", "extlinux"]
|
|
||||||
},
|
|
||||||
"waagent": {
|
"waagent": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
|
@ -22,9 +18,18 @@
|
||||||
},
|
},
|
||||||
"required": ["version"]
|
"required": ["version"]
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
"required": ["waagent"]
|
"required": ["waagent"]
|
||||||
},
|
},
|
||||||
|
"system": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"bootloader": {
|
||||||
|
"type": "string",
|
||||||
|
"enum": ["grub", "extlinux"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
"volume": {
|
"volume": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
|
|
|
@ -29,7 +29,7 @@ class Waagent(Task):
|
||||||
def run(cls, info):
|
def run(cls, info):
|
||||||
from bootstrapvz.common.tools import log_check_call
|
from bootstrapvz.common.tools import log_check_call
|
||||||
import os
|
import os
|
||||||
waagent_version = info.manifest.system['waagent']['version']
|
waagent_version = info.manifest.provider['waagent']['version']
|
||||||
waagent_file = 'WALinuxAgent-' + waagent_version + '.tar.gz'
|
waagent_file = 'WALinuxAgent-' + waagent_version + '.tar.gz'
|
||||||
waagent_url = 'https://github.com/Azure/WALinuxAgent/archive/' + waagent_file
|
waagent_url = 'https://github.com/Azure/WALinuxAgent/archive/' + waagent_file
|
||||||
log_check_call(['wget', '-P', info.root, waagent_url])
|
log_check_call(['wget', '-P', info.root, waagent_url])
|
||||||
|
|
|
@ -38,7 +38,7 @@ def validate_manifest(data, validator, error):
|
||||||
validator(data, os.path.join(os.path.dirname(__file__), 'manifest-schema-s3.json'))
|
validator(data, os.path.join(os.path.dirname(__file__), 'manifest-schema-s3.json'))
|
||||||
|
|
||||||
bootloader = data['system']['bootloader']
|
bootloader = data['system']['bootloader']
|
||||||
virtualization = data['virtualization']
|
virtualization = data['provider']['virtualization']
|
||||||
backing = data['volume']['backing']
|
backing = data['volume']['backing']
|
||||||
partition_type = data['volume']['partitions']['type']
|
partition_type = data['volume']['partitions']['type']
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,9 @@
|
||||||
{
|
{
|
||||||
"$schema": "http://json-schema.org/draft-04/schema#",
|
"$schema": "http://json-schema.org/draft-04/schema#",
|
||||||
"title": "EC2 manifest for instance store AMIs",
|
"title": "EC2 manifest for instance store AMIs",
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"provider": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"credentials": {
|
"credentials": {
|
||||||
|
@ -17,6 +20,8 @@
|
||||||
"pattern": "(^arn:aws:iam::\\d*:user/\\w.*$)|(^\\d{4}-\\d{4}-\\d{4}$)"
|
"pattern": "(^arn:aws:iam::\\d*:user/\\w.*$)|(^\\d{4}-\\d{4}-\\d{4}$)"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
"image": {
|
"image": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
|
|
|
@ -3,15 +3,10 @@
|
||||||
"title": "EC2 manifest",
|
"title": "EC2 manifest",
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"virtualization": { "enum": ["pvm", "hvm"] },
|
"provider": {
|
||||||
"image": {
|
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"description": {
|
"virtualization": { "enum": ["pvm", "hvm"] },
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"credentials": {
|
"credentials": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
|
@ -22,6 +17,17 @@
|
||||||
"type": "string"
|
"type": "string"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["virtualization"]
|
||||||
|
},
|
||||||
|
"image": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"description": {
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
"system": {
|
"system": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
|
|
|
@ -103,7 +103,7 @@ class RegisterAMI(Task):
|
||||||
registration_params['image_location'] = info._ec2['manifest_location']
|
registration_params['image_location'] = info._ec2['manifest_location']
|
||||||
else:
|
else:
|
||||||
root_dev_name = {'pvm': '/dev/sda',
|
root_dev_name = {'pvm': '/dev/sda',
|
||||||
'hvm': '/dev/xvda'}.get(info.manifest.data['virtualization'])
|
'hvm': '/dev/xvda'}.get(info.manifest.provider['virtualization'])
|
||||||
registration_params['root_device_name'] = root_dev_name
|
registration_params['root_device_name'] = root_dev_name
|
||||||
|
|
||||||
from boto.ec2.blockdevicemapping import BlockDeviceType
|
from boto.ec2.blockdevicemapping import BlockDeviceType
|
||||||
|
@ -113,7 +113,7 @@ class RegisterAMI(Task):
|
||||||
registration_params['block_device_map'] = BlockDeviceMapping()
|
registration_params['block_device_map'] = BlockDeviceMapping()
|
||||||
registration_params['block_device_map'][root_dev_name] = block_device
|
registration_params['block_device_map'][root_dev_name] = block_device
|
||||||
|
|
||||||
if info.manifest.data['virtualization'] == 'hvm':
|
if info.manifest.provider['virtualization'] == 'hvm':
|
||||||
registration_params['virtualization_type'] = 'hvm'
|
registration_params['virtualization_type'] = 'hvm'
|
||||||
else:
|
else:
|
||||||
registration_params['virtualization_type'] = 'paravirtual'
|
registration_params['virtualization_type'] = 'paravirtual'
|
||||||
|
|
|
@ -18,9 +18,9 @@ class GetCredentials(Task):
|
||||||
def get_credentials(cls, manifest, keys):
|
def get_credentials(cls, manifest, keys):
|
||||||
from os import getenv
|
from os import getenv
|
||||||
creds = {}
|
creds = {}
|
||||||
if all(key in manifest.data['credentials'] for key in keys):
|
if all(key in manifest.provider['credentials'] for key in keys):
|
||||||
for key in keys:
|
for key in keys:
|
||||||
creds[key] = manifest.data['credentials'][key]
|
creds[key] = manifest.provider['credentials'][key]
|
||||||
return creds
|
return creds
|
||||||
|
|
||||||
def env_key(key):
|
def env_key(key):
|
||||||
|
|
|
@ -28,7 +28,7 @@ def resolve_tasks(taskset, manifest):
|
||||||
loopback.MoveImage,
|
loopback.MoveImage,
|
||||||
])
|
])
|
||||||
|
|
||||||
if manifest.bootstrapper.get('virtio', []):
|
if manifest.provider.get('virtio', []):
|
||||||
from tasks import virtio
|
from tasks import virtio
|
||||||
taskset.update([virtio.VirtIO])
|
taskset.update([virtio.VirtIO])
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
"title": "KVM manifest",
|
"title": "KVM manifest",
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"system": {
|
"provider": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"virtio": {
|
"virtio": {
|
||||||
|
@ -18,7 +18,12 @@
|
||||||
"virtio_ring"]
|
"virtio_ring"]
|
||||||
},
|
},
|
||||||
"minItems": 1
|
"minItems": 1
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
"system": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
"bootloader": {
|
"bootloader": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"enum": ["grub", "extlinux"]
|
"enum": ["grub", "extlinux"]
|
||||||
|
|
|
@ -12,5 +12,5 @@ class VirtIO(Task):
|
||||||
modules = os.path.join(info.root, '/etc/initramfs-tools/modules')
|
modules = os.path.join(info.root, '/etc/initramfs-tools/modules')
|
||||||
with open(modules, "a") as modules_file:
|
with open(modules, "a") as modules_file:
|
||||||
modules_file.write("\n")
|
modules_file.write("\n")
|
||||||
for module in info.manifest.system.get('virtio', []):
|
for module in info.manifest.provider.get('virtio', []):
|
||||||
modules_file.write(module + "\n")
|
modules_file.write(module + "\n")
|
||||||
|
|
|
@ -22,7 +22,7 @@ def resolve_tasks(taskset, manifest):
|
||||||
loopback.MoveImage,
|
loopback.MoveImage,
|
||||||
])
|
])
|
||||||
|
|
||||||
if manifest.bootstrapper.get('guest_additions', False):
|
if manifest.provider.get('guest_additions', False):
|
||||||
from tasks import guest_additions
|
from tasks import guest_additions
|
||||||
taskset.update([guest_additions.CheckGuestAdditionsPath,
|
taskset.update([guest_additions.CheckGuestAdditionsPath,
|
||||||
guest_additions.AddGuestAdditionsPackages,
|
guest_additions.AddGuestAdditionsPackages,
|
||||||
|
|
|
@ -11,7 +11,7 @@ class CheckGuestAdditionsPath(Task):
|
||||||
@classmethod
|
@classmethod
|
||||||
def run(cls, info):
|
def run(cls, info):
|
||||||
import os.path
|
import os.path
|
||||||
guest_additions_path = info.manifest.bootstrapper['guest_additions']
|
guest_additions_path = info.manifest.provider['guest_additions']
|
||||||
if not os.path.exists(guest_additions_path):
|
if not os.path.exists(guest_additions_path):
|
||||||
msg = 'The file {file} does not exist.'.format(file=guest_additions_path)
|
msg = 'The file {file} does not exist.'.format(file=guest_additions_path)
|
||||||
raise TaskError(msg)
|
raise TaskError(msg)
|
||||||
|
@ -43,7 +43,7 @@ class InstallGuestAdditions(Task):
|
||||||
@classmethod
|
@classmethod
|
||||||
def run(cls, info):
|
def run(cls, info):
|
||||||
import os
|
import os
|
||||||
guest_additions_path = info.manifest.bootstrapper['guest_additions']
|
guest_additions_path = info.manifest.provider['guest_additions']
|
||||||
mount_dir = 'mnt/guest_additions'
|
mount_dir = 'mnt/guest_additions'
|
||||||
mount_path = os.path.join(info.root, mount_dir)
|
mount_path = os.path.join(info.root, mount_dir)
|
||||||
os.mkdir(mount_path)
|
os.mkdir(mount_path)
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
{
|
{
|
||||||
"provider": "azure",
|
"provider": {
|
||||||
|
"name": "azure",
|
||||||
|
"waagent": {
|
||||||
|
"version": "2.0.4"
|
||||||
|
}
|
||||||
|
},
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target",
|
"workspace": "/target",
|
||||||
"mirror": "http://ftp.fr.debian.org/debian/"
|
"mirror": "http://ftp.fr.debian.org/debian/"
|
||||||
|
@ -14,10 +19,7 @@
|
||||||
"bootloader": "grub",
|
"bootloader": "grub",
|
||||||
"timezone": "UTC",
|
"timezone": "UTC",
|
||||||
"locale": "en_US",
|
"locale": "en_US",
|
||||||
"charmap": "UTF-8",
|
"charmap": "UTF-8"
|
||||||
"waagent": {
|
|
||||||
"version": "2.0.4"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"packages": {
|
"packages": {
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "hvm",
|
"virtualization": "hvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "hvm",
|
"virtualization": "hvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
---
|
---
|
||||||
provider: "ec2"
|
provider:
|
||||||
|
name: "ec2"
|
||||||
virtualization: "pvm"
|
virtualization: "pvm"
|
||||||
credentials:
|
credentials:
|
||||||
access-key: ""
|
access-key: ""
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,14 +1,12 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null,
|
// "secret-key": null
|
||||||
// "certificate": null,
|
}
|
||||||
// "private-key": null,
|
|
||||||
// "user-id": null
|
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
|
@ -7,8 +8,8 @@
|
||||||
// "certificate": null,
|
// "certificate": null,
|
||||||
// "private-key": null,
|
// "private-key": null,
|
||||||
// "user-id": null
|
// "user-id": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
{
|
{
|
||||||
"provider": "gce",
|
"provider": {
|
||||||
|
"name": "gce"
|
||||||
|
},
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
{
|
{
|
||||||
"provider": "gce",
|
"provider": {
|
||||||
|
"name": "gce"
|
||||||
|
},
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,8 +1,10 @@
|
||||||
{
|
{
|
||||||
"provider": "kvm",
|
"provider": {
|
||||||
|
"name": "kvm",
|
||||||
|
"virtio_modules": [ "virtio_pci", "virtio_blk" ]
|
||||||
|
},
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target",
|
"workspace": "/target"
|
||||||
"mirror": "http://ftp.fr.debian.org/debian/"
|
|
||||||
},
|
},
|
||||||
"image": {
|
"image": {
|
||||||
"name": "debian-{system.release}-{system.architecture}-{%y}{%m}{%d}",
|
"name": "debian-{system.release}-{system.architecture}-{%y}{%m}{%d}",
|
||||||
|
@ -14,8 +16,7 @@
|
||||||
"bootloader": "grub",
|
"bootloader": "grub",
|
||||||
"timezone": "UTC",
|
"timezone": "UTC",
|
||||||
"locale": "en_US",
|
"locale": "en_US",
|
||||||
"charmap": "UTF-8",
|
"charmap": "UTF-8"
|
||||||
"virtio_modules": [ "virtio_pci", "virtio_blk" ]
|
|
||||||
},
|
},
|
||||||
"packages": {},
|
"packages": {},
|
||||||
"volume": {
|
"volume": {
|
||||||
|
|
|
@ -1,8 +1,9 @@
|
||||||
{
|
{
|
||||||
"provider": "kvm",
|
"provider": {
|
||||||
|
"name": "kvm"
|
||||||
|
},
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target",
|
"workspace": "/target"
|
||||||
"mirror": "http://ftp.fr.debian.org/debian/"
|
|
||||||
},
|
},
|
||||||
"image": {
|
"image": {
|
||||||
"name": "debian-{system.release}-{system.architecture}-{%y}{%m}{%d}",
|
"name": "debian-{system.release}-{system.architecture}-{%y}{%m}{%d}",
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
{
|
{
|
||||||
"provider": "ec2",
|
"provider": {
|
||||||
|
"name": "ec2",
|
||||||
"virtualization": "pvm",
|
"virtualization": "pvm",
|
||||||
"credentials": {
|
"credentials": {
|
||||||
// "access-key": null,
|
// "access-key": null,
|
||||||
// "secret-key": null
|
// "secret-key": null
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
{
|
{
|
||||||
"provider": "virtualbox",
|
"provider": {
|
||||||
"bootstrapper": {
|
"name": "virtualbox",
|
||||||
"workspace": "/target",
|
|
||||||
"guest_additions": "/root/images/VBoxGuestAdditions.iso"
|
"guest_additions": "/root/images/VBoxGuestAdditions.iso"
|
||||||
},
|
},
|
||||||
|
"bootstrapper": {
|
||||||
|
"workspace": "/target"
|
||||||
|
},
|
||||||
"image": {
|
"image": {
|
||||||
"name": "debian-{system.release}-{system.architecture}-{%y}{%m}{%d}",
|
"name": "debian-{system.release}-{system.architecture}-{%y}{%m}{%d}",
|
||||||
"description": "Debian {system.release} {system.architecture}"
|
"description": "Debian {system.release} {system.architecture}"
|
||||||
|
|
|
@ -1,8 +1,10 @@
|
||||||
{
|
{
|
||||||
"provider": "virtualbox",
|
"provider": {
|
||||||
|
"name": "virtualbox",
|
||||||
|
"guest_additions": "/root/images/VBoxGuestAdditions.iso"
|
||||||
|
},
|
||||||
"bootstrapper": {
|
"bootstrapper": {
|
||||||
"workspace": "/target"
|
"workspace": "/target"
|
||||||
// "guest_additions": "/root/images/VBoxGuestAdditions.iso"
|
|
||||||
},
|
},
|
||||||
"image": {
|
"image": {
|
||||||
"name": "debian-{system.release}-{system.architecture}-{%y}{%m}{%d}",
|
"name": "debian-{system.release}-{system.architecture}-{%y}{%m}{%d}",
|
||||||
|
|
Loading…
Add table
Reference in a new issue