Commit Graph

3140 Commits

Author SHA1 Message Date
Marcus Schäfer
4ea16ab5e5
Bump version: 9.18.6 → 9.18.7 2019-07-23 09:55:05 +02:00
Marcus Schäfer
94bdd11a3b
Merge pull request #1149 from OSInside/fix_use_of_command_in_destructors
Fixed use of Command calls in destructors
2019-07-23 09:54:46 +02:00
Marcus Schäfer
8facde2ee5
Fixed use of Command calls in destructors
The Command class creates namedtuple to store the result
of the call. That tuple is created inside of the Command
namespace. If called inside of a __del__ destructor which
is often the case in kiwi classes I recently observed an
exception from python saying:

  File "/usr/lib64/python3.6/collections/__init__.py", line 429, in namedtuple
  File "<string>", line 1, in <module>
  ModuleNotFoundError: import of builtins halted; None in sys.modules

I do not understand why this is a problem for python now
and only found the solution in making the command_type variable
a global namedtuple.
2019-07-22 18:12:30 +02:00
Marcus Schäfer
90cbc28c16
Bump version: 9.18.5 → 9.18.6 2019-07-22 09:00:43 +02:00
Marcus Schäfer
554fbb81d4
Merge pull request #1146 from OSInside/fix-pyxattr-requirement
Fix the pyxattr dependency to allow kiwi to function
2019-07-22 09:00:25 +02:00
629f5b4803 Fix the pyxattr dependency to allow kiwi to function
Most Linux distributions offer the pyxattr module, including
openSUSE Tumbleweed. Going forward, we will use the pyxattr
module by default as a dependency and only switch back to the
other xattr module when on older SUSE Linux distributions that
lack the pyxattr module.

Note that because kiwi uses setuptools to create the CLI entry
points, kiwi checks the Python dependencies before executing,
so we change the dependency in the setup.py accordingly so that
it will not fail to start.
2019-07-20 10:43:08 -04:00
Marcus Schäfer
58b5bab9d7
Bump version: 9.18.4 → 9.18.5 2019-07-19 16:47:23 +02:00
Marcus Schäfer
527e8f4ce9
Update spec file requirements for xattr
On suse systems the python-xattr module is used. On any other
distribution the python-pyxattr module is used. This commit
modifies the spec file to reflect the Requires tag appropriately.
On CentOS there is currently no pyxattr build available. Thus we
provide that package for this target in the KIWI Staging area
at Virtualization:Appliances:Staging. There is an ongoing effort
to bring pyxattr to EPEL which would make it available on CentOS
and would obsolete the custom build we did.
2019-07-19 16:42:47 +02:00
Marcus Schäfer
18f3f72152
Bump version: 9.18.3 → 9.18.4 2019-07-19 15:49:37 +02:00
Marcus Schäfer
14f8851750
Update PXE integration test
Move to multibuild, build one standard(uncompressed) filesystem
image and one compressed version. In any case we expect only
one compression process either on the filesystem file or on
the archive creation. This is related to Issue #1039
2019-07-19 15:47:49 +02:00
Marcus Schäfer
d540dd96b5
Merge pull request #1145 from OSInside/refactor_pxe_tarball
Do not recompress PXE image if compressed flag is true
2019-07-19 15:25:10 +02:00
David Cassany
c86efdcd99
Do not recompress PXE image if compressed flag is true
This commit is two fold:

* Refactor PXE builder to make use of the ArchiveTar instead of
  directly calling tar command.
* Do not compress PXE tarball if the contained image is already
  compressed according the type's compressed attribute.

Related to #1039
2019-07-19 13:04:23 +02:00
Marcus Schäfer
65422eaca6
Merge pull request #1144 from OSInside/fix_use_of_FileSystem_Builder
Fixed use of FileSystemBuilder class
2019-07-19 11:46:50 +02:00
Marcus Schäfer
c1d9722ffa
Fixed use of FileSystemBuilder class
This was a broken coding for the construction of a
FileSystemBuilder instance in the PxeBuilder implementation.
The unit testing did not fail due to mocking code.
Integration testing however showed it immediately
2019-07-19 11:15:07 +02:00
Marcus Schäfer
ba0bafd0a3
Merge pull request #1143 from OSInside/support_fs_create_options
Added support for fscreateoptions attribute
2019-07-18 16:49:37 +02:00
Marcus Schäfer
30e18d1398
Added support for fscreateoptions attribute
Along with the fsmountoptions attribute there is now also the
fscreateoptions attribute which allows to control the options
used for creating the filesystem. Please note, it's not kiwi's
task to validate that the given option string is supported
by the selected filesystem. This means providing wrong values
here will cause the build to fail at the time the filesystem
gets created. This Fixes #1109
2019-07-18 15:55:39 +02:00
Marcus Schäfer
444a90ee35
Merge pull request #1141 from OSInside/pxe_install_image_compression
Do not compress the install tarball archive
2019-07-18 09:39:28 +02:00
David Cassany
96419ae757
Do not compress the install tarball archive
Most of the components of the *.install.tar.xz file of a PXE install
image are already compressed, thus it doesn't make much sense to
recompress them again.

Fixes #1032
2019-07-17 16:53:40 +02:00
Marcus Schäfer
6e75c4da8d
Merge pull request #1140 from OSInside/fix_libvirt_metadata_dot_json
virtual_size must be an integer in metadata.json for libvirt vagrant boxes
2019-07-16 21:15:14 +02:00
Dan Čermák
69fc7b1094
virtual_size must be an integer in metadata.json for libvirt vagrant boxes
vagrant-libvirt expects that the parameter virtual_size from metadata.json is an
integer and not a string.
Supplying a string results in a backtrace when the user provides a different
value for libvirt.machine_virtual_size (as the integer is then compared to
string).
2019-07-16 18:24:47 +02:00
Marcus Schäfer
355dc4c4b2
Bump version: 9.18.2 → 9.18.3 2019-07-16 11:58:50 +02:00
Marcus Schäfer
f24da48b33
Merge pull request #1139 from OSInside/fix_iso_efi_with_cdrtools
Fixed ISO creation in EFI mode with cdrtools
2019-07-16 11:58:21 +02:00
Marcus Schäfer
5ef1b59f50
Merge pull request #1138 from OSInside/fix_setup_of_bootloader_files
Fixed setup of bootloader files
2019-07-16 10:05:38 +02:00
Marcus Schäfer
caa9178965
Fixed ISO creation in EFI mode with cdrtools
The changes introduced in #1113 will use the configured bootloader
e.g grub to boot the ISO image in BIOS and EFI mode. The creation
process works flawlessly if xorriso is used. However if cdrtools
are configured the options passed to e.g mkisofs were wrong. In
addition it's not possible to create a hybrid ISO based on
isohybrid if the loader is not isolinux. If cdrtools are in use
the process to make an ISO hybrid bootable is always based on
isohybrid and thus only works with isolinux. This patch also
covers this case with a warning message and the consequence that
we have to skip the hybrid setup in this case.
2019-07-15 12:21:09 +02:00
Marcus Schäfer
cfd8ba7732
Fixed setup of bootloader files
The BootLoaderConfig class interface writes several files
e.g etc/sysconfig/bootloader, boot/grub2/grub.cfg and more.
Depending on the image type some of those files belongs
into the root directory and some belongs into the boot
directory. For standard images both locations points to
the same master root entry point. However for special
types like live systems the root tree and the boot tree
are different targets. For example live root filesystems
are a squashfs compressed image file whereas the plain
booting information lives outside. Because of that this
patch introduces a refactoring of the BootLoaderConfig
class to allow to distinguish between root_dir and
boot_dir paths. In addition the live image builder makes
use of the new concept and thus Fixes #1112
2019-07-15 10:35:54 +02:00
Marcus Schäfer
31952ba319
Merge pull request #1137 from OSInside/fix_machine_id_file_management
Do not create a new machine-id file
2019-07-15 09:23:43 +02:00
David Cassany
afd9b3019a
Do not create a new machine-id file
This commit ensures KIWI is not creating a new machine-id empty file
in case it was not provided during the system installation.

Fixes bsc#1141168
2019-07-12 12:52:28 +02:00
Marcus Schäfer
19c9c1d8cc
Bump version: 9.18.1 → 9.18.2 2019-07-12 10:40:35 +02:00
Marcus Schäfer
d8f782a74e
Merge pull request #1134 from OSInside/update_org_references
Update documentation references
2019-07-12 10:40:15 +02:00
Marcus Schäfer
d09ccc5206
Update documentation references
The kiwi project has been moved into its own upstream
organisation named OSInside. Due to the move some doc
and README references needs to be adapted
2019-07-12 09:45:42 +02:00
Marcus Schäfer
c4c6a36d69
Bump version: 9.18.0 → 9.18.1 2019-07-12 08:41:27 +02:00
Marcus Schäfer
3c750af04d
Merge pull request #1133 from SUSE/centos_spec_fix
Fixed spec for use with Recommends
2019-07-12 08:41:10 +02:00
Marcus Schäfer
583b2313f6
Fixed spec for use with Recommends
The Recommends tag is not known by CentOS/RHEL < v8
2019-07-12 08:40:09 +02:00
Marcus Schäfer
1e4eb22d46
Bump version: 9.17.42 → 9.18.0 2019-07-11 17:07:31 +02:00
Marcus Schäfer
ab02653e0b
Merge pull request #1130 from SUSE/drop_py2_support
Drop support for python2
2019-07-11 17:06:19 +02:00
Marcus Schäfer
baacb61e15
Merge pull request #1132 from SUSE/doc_update_move_of_kiwi_descriptions
Update documentation
2019-07-10 16:44:42 +02:00
Marcus Schäfer
70bc4fdda1
Update documentation
The kiwi-descriptions repository has been moved into the
OSInside organisation
2019-07-10 15:15:58 +02:00
Marcus Schäfer
8b128bf8e4
drop py2 variant of kiwi from completion 2019-07-10 15:07:28 +02:00
ec57224522 Simplify packaging and re-add support for building for CentOS 7 2019-07-10 06:26:37 -04:00
Marcus Schäfer
1566750242
Drop support for python2
Python2 is announced to be unmaintained from Jan 2020.
KIWI supports Python 2.7 and it should not support any python version that
is not maintained upstream. This Fixes #1036
2019-07-10 11:58:57 +02:00
Marcus Schäfer
c5ed2ea33f
Merge pull request #1131 from SUSE/base_mac-for-virtualbox-only
Don't add config.vm.base_mac to libvirt vagrant boxes
2019-07-10 11:14:46 +02:00
Dan Čermák
7c2cb72f50
Don't add config.vm.base_mac to libvirt vagrant boxes
- Refactor VagrantConfigTemplate to no longer require a base_mac by default
- Move _random_mac() to Virtualbox subclass
- Include config.vm.base_mac in Virtualbox boxes via
  get_additional_vagrant_config_settings()

This fixes #1119
2019-07-09 16:17:36 +02:00
Marcus Schäfer
445281c655
Bump version: 9.17.41 → 9.17.42 2019-07-08 12:05:47 +02:00
Marcus Schäfer
614d658f6a
Merge pull request #1129 from SUSE/fix_swap_space_setup
Fixed get_persistent_device_from_unix_node
2019-07-08 12:05:12 +02:00
Marcus Schäfer
7e4bbc0469
Fixed get_persistent_device_from_unix_node
The method get_persistent_device_from_unix_node takes a device
path and looks up it's basename to be present as persistent
variant below the given schema, e.g by-id. However if the
method receives an already persistent device path e.g from
/dev/mapper the persistent schema representation will only
match a numbered dm-N device and not the map name. The method
then returns nothing but should return the original device
path. This caused bad after effects like reported in
Issue SUSE-Enceladus/azure-li-services#163
2019-07-08 11:11:12 +02:00
David Cassany Viladomat
144565ccb7
Merge pull request #1125 from SUSE/custom_vagrantconfig
Add embedded_vagrantfile attribute to vagrantconfig
2019-07-05 15:39:22 +02:00
Dan Čermák
df5ebd2f70
[doc] Add user documentation about the usage of the embedded Vagrantfile
- Document the usage of the `vagrantconfig.embedded_vagrantfile` attribute
- Remove the suggestion to generate the ssh keys during image creation (this
  results in **all** boxes having the same ssh host keys, which is pretty
  dangerous if someone would use a vagrant box in a production environment.)
- Stop recommending veewee, this project is dead
- Replace forgotten hard coded number with {schema_version}
2019-07-05 11:23:02 +02:00
Dan Čermák
669421011e
Add embedded_vagrantfile attribute to vagrantconfig
This element allows the user to specify a relative path to an alternative
Vagrantfile that will be embedded inside the finished Vagrant box.

- update XML schema
- add additional logic to DiskFormatVagrantBase.create_image_format
- add unit test for the custom Vagrantfile
- fix other vagrant unit tests
2019-07-05 10:50:11 +02:00
Marcus Schäfer
6ee4b2e5fa
Merge pull request #1126 from SUSE/fix_runtime_config_tests
Fix test breakage when /etc/kiwi.yml is present
2019-07-05 10:38:28 +02:00
Dan Čermák
9551402d22
Fix test breakage when /etc/kiwi.yml is present
The unit test for the RuntimeConfig class are also testing the default values in
some functions. To work around a possibly existing ~/.config/kiwi/config.yml,
several functions change the value of HOME. This is unfortunately not
sufficient if a /etc/kiwi.yml exists, as that one is taken as a fallback *if*
~/.config/kiwi/config.yml isn't present.

This issue is fixed by creating a default_runtime_config with os.path.exists
patched to return False. Thereby none of the runtime configuration files will be
taken into account.
2019-07-04 15:05:01 +02:00