Add patch to add rnd device to provide faster random on boot.
This commit is contained in:
parent
60ed1eab5a
commit
e452926198
|
@ -0,0 +1,24 @@
|
|||
From 26f205bff526b81080d4c7369d77b0baec90c0a0 Mon Sep 17 00:00:00 2001
|
||||
From: Ian McLeod <imcleod@localhost.localdomain>
|
||||
Date: Mon, 30 Apr 2018 17:04:16 -0500
|
||||
Subject: [PATCH] Initial attempt to add virtio-rng to install VM
|
||||
|
||||
---
|
||||
oz/Guest.py | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/oz/Guest.py b/oz/Guest.py
|
||||
index dff0608..f1869ba 100644
|
||||
--- a/oz/Guest.py
|
||||
+++ b/oz/Guest.py
|
||||
@@ -514,6 +514,10 @@ def _generate_xml(self, bootdev, installdev, kernel=None, initrd=None,
|
||||
self.has_consolelog = True
|
||||
else:
|
||||
self.has_consolelog = False
|
||||
+ # virtio-rng
|
||||
+ virtioRNG = oz.ozutil.lxml_subelement(devices, "rng", None, {'model':'virtio'})
|
||||
+ virtioRNGRate = oz.ozutil.lxml_subelement(virtioRNG, "rate", None, {'bytes':'1024', 'period':'1000'})
|
||||
+ virtioRNCBackend = oz.ozutil.lxml_subelement(virtioRNG, "backend", "/dev/random", {'model':'random'})
|
||||
# boot disk
|
||||
bootDisk = oz.ozutil.lxml_subelement(devices, "disk", None, {'device':'disk', 'type':'file'})
|
||||
oz.ozutil.lxml_subelement(bootDisk, "target", None, {'dev':self.disk_dev, 'bus':self.disk_bus})
|
15
oz.spec
15
oz.spec
|
@ -1,13 +1,14 @@
|
|||
Summary: Library and utilities for automated guest OS installs
|
||||
Name: oz
|
||||
Version: 0.16.0
|
||||
Release: 5%{?dist}
|
||||
Release: 6%{?dist}
|
||||
License: LGPLv2
|
||||
URL: http://github.com/clalancette/oz
|
||||
Source0: https://github.com/clalancette/%{name}/files/1209916/%{name}-%{version}.tar.gz
|
||||
Patch0: s390x-01-add-basic-support.patch
|
||||
Patch1: s390x-02-use-sclplmconsole.patch
|
||||
Patch2: s390x-03-disable-vnc-console.patch
|
||||
Patch3: https://github.com/clalancette/oz/commit/26f205bff526b81080d4c7369d77b0baec90c0a0.patch
|
||||
|
||||
BuildArch: noarch
|
||||
Requires: python2 >= 2.5
|
||||
|
@ -29,8 +30,8 @@ Requires: m2crypto
|
|||
Requires: python2-monotonic
|
||||
|
||||
BuildRequires: python2
|
||||
BuildRequires: python2-devel
|
||||
BuildRequires: python2-setuptools
|
||||
BuildRequires: python-unversioned-command
|
||||
|
||||
%description
|
||||
Oz is a set of libraries and utilities for doing automated guest OS
|
||||
|
@ -41,12 +42,13 @@ installations, with minimal input from the user.
|
|||
%patch0 -p0
|
||||
%patch1 -p0
|
||||
%patch2 -p0
|
||||
%patch3 -p1
|
||||
|
||||
%build
|
||||
python setup.py build
|
||||
python2 setup.py build
|
||||
|
||||
%install
|
||||
python setup.py install --root=$RPM_BUILD_ROOT --skip-build
|
||||
python2 setup.py install --root=$RPM_BUILD_ROOT --skip-build
|
||||
|
||||
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/oz/
|
||||
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/oz/isocontent/
|
||||
|
@ -61,6 +63,8 @@ mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/oz/screenshots/
|
|||
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/oz
|
||||
cp oz.cfg $RPM_BUILD_ROOT%{_sysconfdir}/oz
|
||||
|
||||
sed -i -e 's|/usr/bin/python|/usr/bin/python2|' $RPM_BUILD_ROOT/%{_bindir}/oz*
|
||||
|
||||
%post
|
||||
if [ ! -f %{_sysconfdir}/oz/id_rsa-icicle-gen ]; then
|
||||
ssh-keygen -t rsa -b 2048 -N "" -f %{_sysconfdir}/oz/id_rsa-icicle-gen >& /dev/null
|
||||
|
@ -89,6 +93,9 @@ fi
|
|||
%{_mandir}/man1/*
|
||||
|
||||
%changelog
|
||||
* Mon Dec 10 2018 Kevin Fenzi <kevin@scrye.com> - 0.16.0-6
|
||||
- Add patch to add rnd device to provide faster random on boot.
|
||||
|
||||
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.16.0-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||
|
||||
|
|
Loading…
Reference in New Issue