basebuilder_pel7ppc64lebuilder1
6 years ago
6 changed files with 1532 additions and 0 deletions
@ -0,0 +1,20 @@
@@ -0,0 +1,20 @@
|
||||
--- anaconda-21.48.22.56/pyanaconda/bootloader.py 2016-01-04 18:57:47.074249397 +0100 |
||||
+++ anaconda-21.48.22.56/pyanaconda/bootloader.py 2016-01-04 18:58:51.104255800 +0100 |
||||
@@ -1411,7 +1411,7 @@ |
||||
|
||||
@property |
||||
def stage2_format_types(self): |
||||
- if productName.startswith("Red Hat "): |
||||
+ if productName.startswith("PowerEL"): |
||||
return ["xfs", "ext4", "ext3", "ext2", "btrfs"] |
||||
else: |
||||
return ["ext4", "ext3", "ext2", "btrfs", "xfs"] |
||||
@@ -2105,7 +2105,7 @@ |
||||
|
||||
@property |
||||
def stage2_format_types(self): |
||||
- if productName.startswith("Red Hat "): |
||||
+ if productName.startswith("PowerEL"): |
||||
return ["xfs", "ext4", "ext3", "ext2"] |
||||
else: |
||||
return ["ext4", "ext3", "ext2", "xfs"] |
@ -0,0 +1,12 @@
@@ -0,0 +1,12 @@
|
||||
--- anaconda-21.48.22.56/pyanaconda/constants.py 2016-01-04 19:05:49.784297668 +0100 |
||||
+++ anaconda-21.48.22.56/pyanaconda/constants.py 2016-01-04 19:05:38.074296497 +0100 |
||||
@@ -37,7 +37,7 @@ |
||||
productArch = product.productArch |
||||
bugzillaUrl = product.bugUrl |
||||
isFinal = product.isFinal |
||||
-eulaLocation = "/usr/share/redhat-release/EULA" |
||||
+eulaLocation = "/usr/share/powerel-release/EULA" |
||||
|
||||
# for use in device names, eg: "fedora", "rhel" |
||||
shortProductName = productName.lower() |
||||
|
@ -0,0 +1,111 @@
@@ -0,0 +1,111 @@
|
||||
# |
||||
# powerel.py |
||||
# |
||||
# (c) copyright 2016, VanTosh, All rights reserved. |
||||
# Author: Toshaan Bharvani <toshaan@vantosh.com> |
||||
# License: GNU General Public License v2 |
||||
# |
||||
# This program is free software; you can redistribute it and/or modify |
||||
# it under the terms of the GNU General Public License as published by |
||||
# the Free Software Foundation; either version 2 of the License, or |
||||
# (at your option) any later version. |
||||
# |
||||
# This program is distributed in the hope that it will be useful, |
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
# GNU General Public License for more details. |
||||
# |
||||
# You should have received a copy of the GNU General Public License |
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>. |
||||
# |
||||
|
||||
|
||||
from pyanaconda.installclass import BaseInstallClass |
||||
from pyanaconda.constants import * |
||||
from pyanaconda.product import * |
||||
from pyanaconda.kickstart import getAvailableDiskSpace |
||||
from pyanaconda import network |
||||
from pyanaconda import nm |
||||
from blivet.partspec import PartSpec |
||||
from blivet.platform import platform |
||||
from blivet.devicelibs import swap |
||||
from blivet.size import Size |
||||
import types |
||||
|
||||
|
||||
class InstallClass(BaseInstallClass): |
||||
|
||||
id = "powerel" |
||||
name = "PowerEL" |
||||
sortPriority = 20000 |
||||
|
||||
if not productName.startswith("PowerEL"): |
||||
hidden = True |
||||
|
||||
defaultFS = "xfs" |
||||
|
||||
bootloaderTimeoutDefault = 5 |
||||
# where did this come from ? |
||||
#bootloaderExtraArgs = [] |
||||
|
||||
ignoredPackages = [ ] |
||||
|
||||
installUpdates = False |
||||
|
||||
_l10n_domain = "comps" |
||||
|
||||
efi_dir = "powerel" |
||||
|
||||
help_placeholder = "PowerELPlaceholder.html" |
||||
help_placeholder_with_links = "PowerELPlaceholderWithLinks.html" |
||||
|
||||
def configure(self, anaconda): |
||||
BaseInstallClass.configure(self, anaconda) |
||||
BaseInstallClass.setDefaultPartitioning(self, anaconda.storage) |
||||
|
||||
def setNetworkOnbootDefault(self, ksdata): |
||||
if ksdata.method.method not in ("url", "nfs"): |
||||
return |
||||
if network.has_some_wired_autoconnect_device(): |
||||
return |
||||
# choose the device used during installation |
||||
# (ie for majority of cases the one having the default route) |
||||
dev = network.default_route_device() or network.default_route_device(family="inet6") |
||||
if not dev: |
||||
return |
||||
# ignore wireless (its ifcfgs would need to be handled differently) |
||||
if nm.nm_device_type_is_wifi(dev): |
||||
return |
||||
network.update_onboot_value(dev, "yes", ksdata) |
||||
|
||||
def __init__(self): |
||||
BaseInstallClass.__init__(self) |
||||
|
||||
|
||||
class AtomicInstallClass(BaseInstallClass): |
||||
|
||||
id = "powerelatomic" |
||||
name = "PowerEL Atomic Host" |
||||
sortPriority=21001 |
||||
hidden = not productName.startswith(("PowerEL Atomic Host", "PowerEL Atomic")) |
||||
|
||||
def setDefaultPartitioning(self, storage): |
||||
autorequests = [PartSpec(mountpoint="/", fstype=storage.defaultFSType, size=Size("1GiB"), maxSize=Size("3GiB"), grow=True, lv=True)] |
||||
|
||||
bootreqs = platform.setDefaultPartitioning() |
||||
if bootreqs: |
||||
autorequests.extend(bootreqs) |
||||
|
||||
disk_space = getAvailableDiskSpace(storage) |
||||
swp = swap.swapSuggestion(disk_space=disk_space) |
||||
autorequests.append(PartSpec(fstype="swap", size=swp, grow=False, lv=True, encrypted=True)) |
||||
|
||||
for autoreq in autorequests: |
||||
if autoreq.fstype is None: |
||||
if autoreq.mountpoint == "/boot": |
||||
autoreq.fstype = storage.defaultBootFSType |
||||
autoreq.size = Size("300MiB") |
||||
else: |
||||
autoreq.fstype = storage.defaultFSType |
||||
|
||||
storage.autoPartitionRequests = autorequests |
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,14 @@
@@ -0,0 +1,14 @@
|
||||
diff -uNr anaconda-21.48.22.56__orig/pyanaconda/packaging/yumpayload.py anaconda-21.48.22.56/pyanaconda/packaging/yumpayload.py |
||||
--- anaconda-21.48.22.56__orig/pyanaconda/packaging/yumpayload.py 2015-12-08 14:36:52.533000000 +0000 |
||||
+++ anaconda-21.48.22.56/pyanaconda/packaging/yumpayload.py 2015-12-08 14:38:51.464000000 +0000 |
||||
@@ -648,6 +648,10 @@ |
||||
# so that unattended installations on unreliable networks have |
||||
# a higher chance of finishing successfully |
||||
xdelay = xprogressive_delay() |
||||
+ if not nm_is_connected(): |
||||
+ MAX_METADATA_DOWNLOAD_RETRIES = 1 |
||||
+ else: |
||||
+ MAX_METADATA_DOWNLOAD_RETRIES = 10 |
||||
for retry_count in xrange(0, MAX_METADATA_DOWNLOAD_RETRIES + 1): |
||||
if retry_count > 0: |
||||
# introduce a retry delay |
@ -0,0 +1,29 @@
@@ -0,0 +1,29 @@
|
||||
--- anaconda-21.48.22.56/pyanaconda/bootloader.py 2016-02-10 18:08:58.296322802 +0100 |
||||
+++ anaconda-21.48.22.56/pyanaconda/bootloader.py 2016-02-10 18:11:07.476335720 +0100 |
||||
@@ -1569,7 +1569,7 @@ |
||||
rc = iutil.execInSysroot("grub2-mkconfig", |
||||
["-o", self.config_file]) |
||||
if rc: |
||||
- raise BootLoaderError("failed to write boot loader configuration") |
||||
+ raise BootLoaderError("failed to write boot loader configuration [%s] (%s)" % (self.config_file,rc)) |
||||
|
||||
# |
||||
# installation |
||||
@@ -2017,7 +2017,7 @@ |
||||
else: |
||||
self.updateNVRAMBootList() |
||||
|
||||
- super(IPSeriesGRUB2, self).install(args=["--no-nvram"]) |
||||
+ super(IPSeriesGRUB2, self).install(args=["--no-nvram","--force"]) |
||||
|
||||
# This will update the PowerPC's (ppc) bios boot devive order list |
||||
def updateNVRAMBootList(self): |
||||
@@ -2054,7 +2054,7 @@ |
||||
|
||||
rc = iutil.execWithRedirect("nvram", ["--update-config", update_value]) |
||||
if rc: |
||||
- log.error("Failed to update new boot device order") |
||||
+ log.error("Failed to update new boot device order [%s] (%s)" % (update_value,rc)) |
||||
|
||||
# |
||||
# In addition to the normal grub configuration variable, add one more to set the size of the |
Loading…
Reference in new issue