|
|
76240a |
From 86e1556555fde19d3b6bfa7e280c8d9faf6243d3 Mon Sep 17 00:00:00 2001
|
|
|
76240a |
From: Matej Tyc <matyc@redhat.com>
|
|
|
76240a |
Date: Mon, 16 Aug 2021 13:08:10 +0200
|
|
|
76240a |
Subject: [PATCH] Add ISM Official kickstarts
|
|
|
76240a |
|
|
|
76240a |
---
|
|
|
76240a |
.../rhel8/kickstart/ssg-rhel8-ism_o-ks.cfg | 116 ++++++++++++++++++
|
|
|
76240a |
.../rhel9/kickstart/ssg-rhel9-ism_o-ks.cfg | 116 ++++++++++++++++++
|
|
|
76240a |
2 files changed, 232 insertions(+)
|
|
|
76240a |
create mode 100644 products/rhel8/kickstart/ssg-rhel8-ism_o-ks.cfg
|
|
|
76240a |
create mode 100644 products/rhel9/kickstart/ssg-rhel9-ism_o-ks.cfg
|
|
|
76240a |
|
|
|
76240a |
diff --git a/products/rhel8/kickstart/ssg-rhel8-ism_o-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-ism_o-ks.cfg
|
|
|
76240a |
new file mode 100644
|
|
|
76240a |
index 0000000000..d84d98b12d
|
|
|
76240a |
--- /dev/null
|
|
|
76240a |
+++ b/products/rhel8/kickstart/ssg-rhel8-ism_o-ks.cfg
|
|
|
76240a |
@@ -0,0 +1,116 @@
|
|
|
76240a |
+# SCAP Security Guide ISM Official profile kickstart for Red Hat Enterprise Linux 8 Server
|
|
|
76240a |
+# Version: 0.0.1
|
|
|
76240a |
+# Date: 2021-08-16
|
|
|
76240a |
+#
|
|
|
76240a |
+# Based on:
|
|
|
76240a |
+# https://pykickstart.readthedocs.io/en/latest/
|
|
|
76240a |
+# https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html-single/performing_an_advanced_rhel_installation/index#performing_an_automated_installation_using_kickstart
|
|
|
76240a |
+
|
|
|
76240a |
+# Specify installation method to use for installation
|
|
|
76240a |
+# To use a different one comment out the 'url' one below, update
|
|
|
76240a |
+# the selected choice with proper options & un-comment it
|
|
|
76240a |
+#
|
|
|
76240a |
+# Install from an installation tree on a remote server via FTP or HTTP:
|
|
|
76240a |
+# --url the URL to install from
|
|
|
76240a |
+#
|
|
|
76240a |
+# Example:
|
|
|
76240a |
+#
|
|
|
76240a |
+# url --url=http://192.168.122.1/image
|
|
|
76240a |
+#
|
|
|
76240a |
+# Modify concrete URL in the above example appropriately to reflect the actual
|
|
|
76240a |
+# environment machine is to be installed in
|
|
|
76240a |
+#
|
|
|
76240a |
+# Other possible / supported installation methods:
|
|
|
76240a |
+# * install from the first CD-ROM/DVD drive on the system:
|
|
|
76240a |
+#
|
|
|
76240a |
+# cdrom
|
|
|
76240a |
+#
|
|
|
76240a |
+# * install from a directory of ISO images on a local drive:
|
|
|
76240a |
+#
|
|
|
76240a |
+# harddrive --partition=hdb2 --dir=/tmp/install-tree
|
|
|
76240a |
+#
|
|
|
76240a |
+# * install from provided NFS server:
|
|
|
76240a |
+#
|
|
|
76240a |
+# nfs --server=<hostname> --dir=<directory> [--opts=<nfs options>]
|
|
|
76240a |
+#
|
|
|
76240a |
+
|
|
|
76240a |
+# Set language to use during installation and the default language to use on the installed system (required)
|
|
|
76240a |
+lang en_US.UTF-8
|
|
|
76240a |
+
|
|
|
76240a |
+# Set system keyboard type / layout (required)
|
|
|
76240a |
+keyboard us
|
|
|
76240a |
+
|
|
|
76240a |
+# Configure network information for target system and activate network devices in the installer environment (optional)
|
|
|
76240a |
+# --onboot enable device at a boot time
|
|
|
76240a |
+# --device device to be activated and / or configured with the network command
|
|
|
76240a |
+# --bootproto method to obtain networking configuration for device (default dhcp)
|
|
|
76240a |
+# --noipv6 disable IPv6 on this device
|
|
|
76240a |
+#
|
|
|
76240a |
+#
|
|
|
76240a |
+network --onboot yes --device eth0 --bootproto dhcp --noipv6
|
|
|
76240a |
+
|
|
|
76240a |
+# Set the system's root password (required)
|
|
|
76240a |
+# Plaintext password is: server
|
|
|
76240a |
+# Refer to e.g. https://pykickstart.readthedocs.io/en/latest/commands.html#rootpw to see how to create
|
|
|
76240a |
+# encrypted password form for different plaintext password
|
|
|
76240a |
+rootpw --iscrypted $6$/0RYeeRdK70ynvYz$jH2ZN/80HM6DjndHMxfUF9KIibwipitvizzXDH1zW.fTjyD3RD3tkNdNUaND18B/XqfAUW3vy1uebkBybCuIm0
|
|
|
76240a |
+
|
|
|
76240a |
+# The selected profile will restrict root login
|
|
|
76240a |
+# Add a user that can login and escalate privileges
|
|
|
76240a |
+# Plaintext password is: admin123
|
|
|
76240a |
+user --name=admin --groups=wheel --password=$6$Ga6ZnIlytrWpuCzO$q0LqT1USHpahzUafQM9jyHCY9BiE5/ahXLNWUMiVQnFGblu0WWGZ1e6icTaCGO4GNgZNtspp1Let/qpM7FMVB0 --iscrypted
|
|
|
76240a |
+
|
|
|
76240a |
+# Configure firewall settings for the system (optional)
|
|
|
76240a |
+# --enabled reject incoming connections that are not in response to outbound requests
|
|
|
76240a |
+# --ssh allow sshd service through the firewall
|
|
|
76240a |
+firewall --enabled --ssh
|
|
|
76240a |
+
|
|
|
76240a |
+# Set up the authentication options for the system (required)
|
|
|
76240a |
+# sssd profile sets sha512 to hash passwords
|
|
|
76240a |
+# passwords are shadowed by default
|
|
|
76240a |
+# See the manual page for authselect-profile for a complete list of possible options.
|
|
|
76240a |
+authselect select sssd
|
|
|
76240a |
+
|
|
|
76240a |
+# State of SELinux on the installed system (optional)
|
|
|
76240a |
+# Defaults to enforcing
|
|
|
76240a |
+selinux --enforcing
|
|
|
76240a |
+
|
|
|
76240a |
+# Set the system time zone (required)
|
|
|
76240a |
+timezone --utc America/New_York
|
|
|
76240a |
+
|
|
|
76240a |
+# Specify how the bootloader should be installed (required)
|
|
|
76240a |
+bootloader --location=mbr --append="crashkernel=auto rhgb quiet"
|
|
|
76240a |
+
|
|
|
76240a |
+# Initialize (format) all disks (optional)
|
|
|
76240a |
+zerombr
|
|
|
76240a |
+
|
|
|
76240a |
+# The following partition layout scheme assumes disk of size 20GB or larger
|
|
|
76240a |
+# Modify size of partitions appropriately to reflect actual machine's hardware
|
|
|
76240a |
+#
|
|
|
76240a |
+# Remove Linux partitions from the system prior to creating new ones (optional)
|
|
|
76240a |
+# --linux erase all Linux partitions
|
|
|
76240a |
+# --initlabel initialize the disk label to the default based on the underlying architecture
|
|
|
76240a |
+clearpart --linux --initlabel
|
|
|
76240a |
+
|
|
|
76240a |
+# Create primary system partitions (required for installs)
|
|
|
76240a |
+autopart
|
|
|
76240a |
+
|
|
|
76240a |
+# Harden installation with Essential Eight profile
|
|
|
76240a |
+# For more details and configuration options see
|
|
|
76240a |
+# https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html-single/performing_an_advanced_rhel_installation/index#addon-org_fedora_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program
|
|
|
76240a |
+%addon org_fedora_oscap
|
|
|
76240a |
+ content-type = scap-security-guide
|
|
|
76240a |
+ profile = xccdf_org.ssgproject.content_profile_ism_o
|
|
|
76240a |
+%end
|
|
|
76240a |
+
|
|
|
76240a |
+# Packages selection (%packages section is required)
|
|
|
76240a |
+%packages
|
|
|
76240a |
+
|
|
|
76240a |
+# Require @Base
|
|
|
76240a |
+@Base
|
|
|
76240a |
+
|
|
|
76240a |
+%end # End of %packages section
|
|
|
76240a |
+
|
|
|
76240a |
+# Reboot after the installation is complete (optional)
|
|
|
76240a |
+# --eject attempt to eject CD or DVD media before rebooting
|
|
|
76240a |
+reboot --eject
|
|
|
76240a |
diff --git a/products/rhel9/kickstart/ssg-rhel9-ism_o-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-ism_o-ks.cfg
|
|
|
76240a |
new file mode 100644
|
|
|
76240a |
index 0000000000..517919539a
|
|
|
76240a |
--- /dev/null
|
|
|
76240a |
+++ b/products/rhel9/kickstart/ssg-rhel9-ism_o-ks.cfg
|
|
|
76240a |
@@ -0,0 +1,116 @@
|
|
|
76240a |
+# SCAP Security Guide ISM Official profile kickstart for Red Hat Enterprise Linux 9 Server
|
|
|
76240a |
+# Version: 0.0.1
|
|
|
76240a |
+# Date: 2021-08-16
|
|
|
76240a |
+#
|
|
|
76240a |
+# Based on:
|
|
|
76240a |
+# https://pykickstart.readthedocs.io/en/latest/
|
|
|
76240a |
+# https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html-single/performing_an_advanced_rhel_installation/index#performing_an_automated_installation_using_kickstart
|
|
|
76240a |
+
|
|
|
76240a |
+# Specify installation method to use for installation
|
|
|
76240a |
+# To use a different one comment out the 'url' one below, update
|
|
|
76240a |
+# the selected choice with proper options & un-comment it
|
|
|
76240a |
+#
|
|
|
76240a |
+# Install from an installation tree on a remote server via FTP or HTTP:
|
|
|
76240a |
+# --url the URL to install from
|
|
|
76240a |
+#
|
|
|
76240a |
+# Example:
|
|
|
76240a |
+#
|
|
|
76240a |
+# url --url=http://192.168.122.1/image
|
|
|
76240a |
+#
|
|
|
76240a |
+# Modify concrete URL in the above example appropriately to reflect the actual
|
|
|
76240a |
+# environment machine is to be installed in
|
|
|
76240a |
+#
|
|
|
76240a |
+# Other possible / supported installation methods:
|
|
|
76240a |
+# * install from the first CD-ROM/DVD drive on the system:
|
|
|
76240a |
+#
|
|
|
76240a |
+# cdrom
|
|
|
76240a |
+#
|
|
|
76240a |
+# * install from a directory of ISO images on a local drive:
|
|
|
76240a |
+#
|
|
|
76240a |
+# harddrive --partition=hdb2 --dir=/tmp/install-tree
|
|
|
76240a |
+#
|
|
|
76240a |
+# * install from provided NFS server:
|
|
|
76240a |
+#
|
|
|
76240a |
+# nfs --server=<hostname> --dir=<directory> [--opts=<nfs options>]
|
|
|
76240a |
+#
|
|
|
76240a |
+
|
|
|
76240a |
+# Set language to use during installation and the default language to use on the installed system (required)
|
|
|
76240a |
+lang en_US.UTF-8
|
|
|
76240a |
+
|
|
|
76240a |
+# Set system keyboard type / layout (required)
|
|
|
76240a |
+keyboard us
|
|
|
76240a |
+
|
|
|
76240a |
+# Configure network information for target system and activate network devices in the installer environment (optional)
|
|
|
76240a |
+# --onboot enable device at a boot time
|
|
|
76240a |
+# --device device to be activated and / or configured with the network command
|
|
|
76240a |
+# --bootproto method to obtain networking configuration for device (default dhcp)
|
|
|
76240a |
+# --noipv6 disable IPv6 on this device
|
|
|
76240a |
+#
|
|
|
76240a |
+#
|
|
|
76240a |
+network --onboot yes --device eth0 --bootproto dhcp --noipv6
|
|
|
76240a |
+
|
|
|
76240a |
+# Set the system's root password (required)
|
|
|
76240a |
+# Plaintext password is: server
|
|
|
76240a |
+# Refer to e.g. https://pykickstart.readthedocs.io/en/latest/commands.html#rootpw to see how to create
|
|
|
76240a |
+# encrypted password form for different plaintext password
|
|
|
76240a |
+rootpw --iscrypted $6$/0RYeeRdK70ynvYz$jH2ZN/80HM6DjndHMxfUF9KIibwipitvizzXDH1zW.fTjyD3RD3tkNdNUaND18B/XqfAUW3vy1uebkBybCuIm0
|
|
|
76240a |
+
|
|
|
76240a |
+# The selected profile will restrict root login
|
|
|
76240a |
+# Add a user that can login and escalate privileges
|
|
|
76240a |
+# Plaintext password is: admin123
|
|
|
76240a |
+user --name=admin --groups=wheel --password=$6$Ga6ZnIlytrWpuCzO$q0LqT1USHpahzUafQM9jyHCY9BiE5/ahXLNWUMiVQnFGblu0WWGZ1e6icTaCGO4GNgZNtspp1Let/qpM7FMVB0 --iscrypted
|
|
|
76240a |
+
|
|
|
76240a |
+# Configure firewall settings for the system (optional)
|
|
|
76240a |
+# --enabled reject incoming connections that are not in response to outbound requests
|
|
|
76240a |
+# --ssh allow sshd service through the firewall
|
|
|
76240a |
+firewall --enabled --ssh
|
|
|
76240a |
+
|
|
|
76240a |
+# Set up the authentication options for the system (required)
|
|
|
76240a |
+# sssd profile sets sha512 to hash passwords
|
|
|
76240a |
+# passwords are shadowed by default
|
|
|
76240a |
+# See the manual page for authselect-profile for a complete list of possible options.
|
|
|
76240a |
+authselect select sssd
|
|
|
76240a |
+
|
|
|
76240a |
+# State of SELinux on the installed system (optional)
|
|
|
76240a |
+# Defaults to enforcing
|
|
|
76240a |
+selinux --enforcing
|
|
|
76240a |
+
|
|
|
76240a |
+# Set the system time zone (required)
|
|
|
76240a |
+timezone --utc America/New_York
|
|
|
76240a |
+
|
|
|
76240a |
+# Specify how the bootloader should be installed (required)
|
|
|
76240a |
+bootloader --location=mbr --append="crashkernel=auto rhgb quiet"
|
|
|
76240a |
+
|
|
|
76240a |
+# Initialize (format) all disks (optional)
|
|
|
76240a |
+zerombr
|
|
|
76240a |
+
|
|
|
76240a |
+# The following partition layout scheme assumes disk of size 20GB or larger
|
|
|
76240a |
+# Modify size of partitions appropriately to reflect actual machine's hardware
|
|
|
76240a |
+#
|
|
|
76240a |
+# Remove Linux partitions from the system prior to creating new ones (optional)
|
|
|
76240a |
+# --linux erase all Linux partitions
|
|
|
76240a |
+# --initlabel initialize the disk label to the default based on the underlying architecture
|
|
|
76240a |
+clearpart --linux --initlabel
|
|
|
76240a |
+
|
|
|
76240a |
+# Create primary system partitions (required for installs)
|
|
|
76240a |
+autopart
|
|
|
76240a |
+
|
|
|
76240a |
+# Harden installation with Essential Eight profile
|
|
|
76240a |
+# For more details and configuration options see
|
|
|
76240a |
+# https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html-single/performing_an_advanced_rhel_installation/index#addon-org_fedora_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program
|
|
|
76240a |
+%addon com_redhat_oscap
|
|
|
76240a |
+ content-type = scap-security-guide
|
|
|
76240a |
+ profile = xccdf_org.ssgproject.content_profile_ism_o
|
|
|
76240a |
+%end
|
|
|
76240a |
+
|
|
|
76240a |
+# Packages selection (%packages section is required)
|
|
|
76240a |
+%packages
|
|
|
76240a |
+
|
|
|
76240a |
+# Require @Base
|
|
|
76240a |
+@Base
|
|
|
76240a |
+
|
|
|
76240a |
+%end # End of %packages section
|
|
|
76240a |
+
|
|
|
76240a |
+# Reboot after the installation is complete (optional)
|
|
|
76240a |
+# --eject attempt to eject CD or DVD media before rebooting
|
|
|
76240a |
+reboot --eject
|