Add qcow2 image type
Very similar to partitioned-disk, image is named disk.qcow2 instead of disk.img
This commit is contained in:
parent
c5a07ff80f
commit
af68a98abe
@ -97,6 +97,7 @@ Requires: libgit2-glib
|
|||||||
Requires: python-flask
|
Requires: python-flask
|
||||||
Requires: python-gevent
|
Requires: python-gevent
|
||||||
Requires: anaconda-tui
|
Requires: anaconda-tui
|
||||||
|
Requires: qemu-img
|
||||||
|
|
||||||
%{?systemd_requires}
|
%{?systemd_requires}
|
||||||
BuildRequires: systemd
|
BuildRequires: systemd
|
||||||
|
56
share/composer/qcow2.ks
Normal file
56
share/composer/qcow2.ks
Normal file
@ -0,0 +1,56 @@
|
|||||||
|
# Lorax Composer qcow2 output kickstart template
|
||||||
|
|
||||||
|
#
|
||||||
|
sshpw --username=root --plaintext randOmStrinGhERE
|
||||||
|
# Firewall configuration
|
||||||
|
firewall --enabled
|
||||||
|
|
||||||
|
# Root password
|
||||||
|
rootpw --plaintext removethispw
|
||||||
|
# Network information
|
||||||
|
network --bootproto=dhcp --onboot=on --activate
|
||||||
|
# System authorization information
|
||||||
|
auth --useshadow --enablemd5
|
||||||
|
# System keyboard
|
||||||
|
keyboard --xlayouts=us --vckeymap=us
|
||||||
|
# System language
|
||||||
|
lang en_US.UTF-8
|
||||||
|
# SELinux configuration
|
||||||
|
selinux --enforcing
|
||||||
|
# Installation logging level
|
||||||
|
logging --level=info
|
||||||
|
# Shutdown after installation
|
||||||
|
shutdown
|
||||||
|
# System timezone
|
||||||
|
timezone US/Eastern
|
||||||
|
# System bootloader configuration
|
||||||
|
bootloader --location=mbr
|
||||||
|
# Clear the Master Boot Record
|
||||||
|
zerombr
|
||||||
|
# Partition clearing information
|
||||||
|
clearpart --all
|
||||||
|
# Disk partitioning information
|
||||||
|
part / --fstype="ext4" --size=4000
|
||||||
|
part swap --size=1000
|
||||||
|
|
||||||
|
%post
|
||||||
|
# Remove root password
|
||||||
|
passwd -d root > /dev/null
|
||||||
|
|
||||||
|
# Remove random-seed
|
||||||
|
rm /var/lib/systemd/random-seed
|
||||||
|
%end
|
||||||
|
|
||||||
|
%packages
|
||||||
|
kernel
|
||||||
|
-dracut-config-rescue
|
||||||
|
|
||||||
|
shim
|
||||||
|
shim-ia32
|
||||||
|
grub2
|
||||||
|
grub2-efi
|
||||||
|
grub2-efi-*-cdboot
|
||||||
|
grub2-efi-ia32
|
||||||
|
efibootmgr
|
||||||
|
|
||||||
|
# NOTE lorax-composer will add the recipe packages below here, including the final %end
|
@ -247,7 +247,7 @@ def compose_args(compose_type):
|
|||||||
"live_rootfs_keep_size": False,
|
"live_rootfs_keep_size": False,
|
||||||
"live_rootfs_size": 0,
|
"live_rootfs_size": 0,
|
||||||
"qcow2": False,
|
"qcow2": False,
|
||||||
"qcow2_arg": [],
|
"qcow2_args": [],
|
||||||
"image_name": default_image_name("xz", "root.tar"),
|
"image_name": default_image_name("xz", "root.tar"),
|
||||||
"image_only": True,
|
"image_only": True,
|
||||||
"app_name": None,
|
"app_name": None,
|
||||||
@ -266,7 +266,7 @@ def compose_args(compose_type):
|
|||||||
"live_rootfs_keep_size": False,
|
"live_rootfs_keep_size": False,
|
||||||
"live_rootfs_size": 0,
|
"live_rootfs_size": 0,
|
||||||
"qcow2": False,
|
"qcow2": False,
|
||||||
"qcow2_arg": [],
|
"qcow2_args": [],
|
||||||
"image_name": "live.iso",
|
"image_name": "live.iso",
|
||||||
"fs_label": "Anaconda", # Live booting may expect this to be 'Anaconda'
|
"fs_label": "Anaconda", # Live booting may expect this to be 'Anaconda'
|
||||||
"image_only": False,
|
"image_only": False,
|
||||||
@ -286,7 +286,7 @@ def compose_args(compose_type):
|
|||||||
"live_rootfs_keep_size": False,
|
"live_rootfs_keep_size": False,
|
||||||
"live_rootfs_size": 0,
|
"live_rootfs_size": 0,
|
||||||
"qcow2": False,
|
"qcow2": False,
|
||||||
"qcow2_arg": [],
|
"qcow2_args": [],
|
||||||
"image_name": "disk.img",
|
"image_name": "disk.img",
|
||||||
"fs_label": "",
|
"fs_label": "",
|
||||||
"image_only": True,
|
"image_only": True,
|
||||||
@ -294,6 +294,26 @@ def compose_args(compose_type):
|
|||||||
"app_template": None,
|
"app_template": None,
|
||||||
"app_file": None
|
"app_file": None
|
||||||
},
|
},
|
||||||
|
"qcow2": {"make_iso": False,
|
||||||
|
"make_disk": True,
|
||||||
|
"make_fsimage": False,
|
||||||
|
"make_appliance": False,
|
||||||
|
"make_ami": False,
|
||||||
|
"make_tar": False,
|
||||||
|
"make_pxe_live": False,
|
||||||
|
"make_ostree_live": False,
|
||||||
|
"ostree": False,
|
||||||
|
"live_rootfs_keep_size": False,
|
||||||
|
"live_rootfs_size": 0,
|
||||||
|
"qcow2": True,
|
||||||
|
"qcow2_args": [],
|
||||||
|
"image_name": "disk.qcow2",
|
||||||
|
"fs_label": "",
|
||||||
|
"image_only": True,
|
||||||
|
"app_name": None,
|
||||||
|
"app_template": None,
|
||||||
|
"app_file": None
|
||||||
|
},
|
||||||
}
|
}
|
||||||
return _MAP[compose_type]
|
return _MAP[compose_type]
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user