forked from srbala/fedora-kickstarts
manipulate network service in %post (#1369794)
Due to #1369794 , anaconda cannot currently manipulate sysv services in F25+. So to work around this, take 'network' out of the services lines in all kickstarts and instead manipulate it in the %post section, with chkconfig. Also remove rsyslog from the Atomic image services line because it doesn't appear to be included in the OStree tree at present and so attempting to enable the service breaks Atomic image compose, see e.g.: https://kojipkgs.fedoraproject.org//work/tasks/9022/15349022/oz-x86_64.log also correct the name of the ssh service in fedora-arm-base.ks; it's sshd not ssh.
This commit is contained in:
parent
b3baf2ecec
commit
4af7364074
@ -9,7 +9,6 @@ selinux --permissive
|
||||
firewall --disabled
|
||||
bootloader --timeout=1 --append="acpi=force"
|
||||
network --bootproto=dhcp --device=eth0 --onboot=on
|
||||
services --enabled=network
|
||||
|
||||
# Uncomment the next line
|
||||
# to make the root password be thincrust
|
||||
@ -95,5 +94,9 @@ generic-logos
|
||||
#
|
||||
%post
|
||||
|
||||
# Enable network service here, as doing it in the services line
|
||||
# fails due to RHBZ #1369794
|
||||
/sbin/chkconfig network on
|
||||
|
||||
%end
|
||||
|
||||
|
@ -14,7 +14,7 @@ part / --size=3584 --fstype ext4
|
||||
# make sure that initial-setup runs and lets us do all the configuration bits
|
||||
firstboot --reconfig
|
||||
|
||||
services --enabled=ssh,NetworkManager,avahi-daemon,rsyslog,chronyd,initial-setup --disabled=network
|
||||
services --enabled=sshd,NetworkManager,avahi-daemon,rsyslog,chronyd,initial-setup
|
||||
|
||||
%include fedora-repo.ks
|
||||
|
||||
@ -74,5 +74,9 @@ systemctl mask tmp.mount
|
||||
|
||||
dnf -y remove dracut-config-generic
|
||||
|
||||
# Disable network service here, as doing it in the services line
|
||||
# fails due to RHBZ #1369794
|
||||
/sbin/chkconfig network off
|
||||
|
||||
%end
|
||||
|
||||
|
@ -21,8 +21,7 @@ firewall --disabled
|
||||
bootloader --timeout=1 --append="no_timer_check console=tty1 console=ttyS0,115200n8"
|
||||
|
||||
network --bootproto=dhcp --device=link --activate --onboot=on
|
||||
services --disabled=network
|
||||
services --enabled=sshd,rsyslog,cloud-init,cloud-init-local,cloud-config,cloud-final
|
||||
services --enabled=sshd,cloud-init,cloud-init-local,cloud-config,cloud-final
|
||||
|
||||
zerombr
|
||||
clearpart --all
|
||||
@ -125,5 +124,9 @@ echo "(Don't worry -- that out-of-space error was expected.)"
|
||||
echo "Adding Developer Mode GRUB2 menu item."
|
||||
/usr/libexec/atomic-devmode/bootentry add
|
||||
|
||||
# Disable network service here, as doing it in the services line
|
||||
# fails due to RHBZ #1369794
|
||||
/sbin/chkconfig network off
|
||||
|
||||
%end
|
||||
|
||||
|
@ -14,7 +14,7 @@ network --bootproto=dhcp --device=link --activate
|
||||
part / --fstype="ext4" --size=6000
|
||||
part /boot --size=500 --fstype="ext4"
|
||||
shutdown
|
||||
services --disabled=docker-storage-setup,network
|
||||
services --disabled=docker-storage-setup
|
||||
services --enabled=NetworkManager,sshd,cloud-init,cloud-init-local,cloud-config,cloud-final
|
||||
|
||||
ostreesetup --nogpg --osname=fedora-atomic --remote=fedora-atomic --url=http://kojipkgs.fedoraproject.org/mash/atomic/22/ --ref=fedora-atomic/f22/x86_64/docker-host
|
||||
@ -28,4 +28,9 @@ userdel -r none
|
||||
# We copy content of separate /boot partition to root part when building live squashfs image,
|
||||
# and we don't want systemd to try to mount it when pxe booting
|
||||
cat /dev/null > /etc/fstab
|
||||
|
||||
# Disable network service here, as doing it in the services line
|
||||
# fails due to RHBZ #1369794
|
||||
/sbin/chkconfig network off
|
||||
|
||||
%end
|
||||
|
@ -39,7 +39,7 @@ firewall --disabled
|
||||
bootloader --timeout=1 --append="no_timer_check console=tty1 console=ttyS0,115200n8" --extlinux
|
||||
|
||||
network --bootproto=dhcp --device=link --activate --onboot=on
|
||||
services --enabled=network,sshd,rsyslog,cloud-init,cloud-init-local,cloud-config,cloud-final
|
||||
services --enabled=sshd,rsyslog,cloud-init,cloud-init-local,cloud-config,cloud-final
|
||||
|
||||
zerombr
|
||||
clearpart --all
|
||||
@ -265,5 +265,9 @@ echo "(Don't worry -- that out-of-space error was expected.)"
|
||||
# For trac ticket https://fedorahosted.org/cloud/ticket/128
|
||||
rm -f /etc/sysconfig/network-scripts/ifcfg-ens3
|
||||
|
||||
# Enable network service here, as doing it in the services line
|
||||
# fails due to RHBZ #1369794
|
||||
/sbin/chkconfig network on
|
||||
|
||||
%end
|
||||
|
||||
|
@ -26,7 +26,7 @@ firewall --disabled
|
||||
bootloader --timeout=1 --append="no_timer_check console=tty1 console=ttyS0,115200n8" --extlinux
|
||||
|
||||
network --bootproto=dhcp --device=eth0 --activate --onboot=on
|
||||
services --enabled=network,sshd,rsyslog,cloud-init,cloud-init-local,cloud-config,cloud-final
|
||||
services --enabled=sshd,rsyslog,cloud-init,cloud-init-local,cloud-config,cloud-final
|
||||
|
||||
zerombr
|
||||
clearpart --all
|
||||
@ -219,5 +219,9 @@ dd bs=1M if=/dev/zero of=/var/tmp/zeros || :
|
||||
rm -f /var/tmp/zeros
|
||||
echo "(Don't worry -- that out-of-space error was expected.)"
|
||||
|
||||
# Enable network service here, as doing it in the services line
|
||||
# fails due to RHBZ #1369794
|
||||
/sbin/chkconfig network on
|
||||
|
||||
%end
|
||||
|
||||
|
@ -17,7 +17,7 @@ firewall --disabled
|
||||
bootloader --timeout=1 --append="no_timer_check console=tty1 console=ttyS0,115200n8" --extlinux
|
||||
|
||||
network --bootproto=dhcp --device=eth0 --activate --onboot=on
|
||||
services --enabled=network,sshd,rsyslog,cloud-init,cloud-init-local,cloud-config,cloud-final
|
||||
services --enabled=sshd,rsyslog,cloud-init,cloud-init-local,cloud-config,cloud-final
|
||||
|
||||
zerombr
|
||||
clearpart --all
|
||||
@ -211,5 +211,9 @@ dd bs=1M if=/dev/zero of=/var/tmp/zeros || :
|
||||
rm -f /var/tmp/zeros
|
||||
echo "(Don't worry -- that out-of-space error was expected.)"
|
||||
|
||||
# Enable network service here, as doing it in the services line
|
||||
# fails due to RHBZ #1369794
|
||||
/sbin/chkconfig network on
|
||||
|
||||
%end
|
||||
|
||||
|
@ -17,7 +17,7 @@ xconfig --startxonboot
|
||||
zerombr
|
||||
clearpart --all
|
||||
part / --size 5120 --fstype ext4
|
||||
services --enabled=NetworkManager,ModemManager --disabled=network,sshd
|
||||
services --enabled=NetworkManager,ModemManager --disabled=sshd
|
||||
network --bootproto=dhcp --device=link --activate
|
||||
shutdown
|
||||
|
||||
@ -321,6 +321,10 @@ echo 'File created by kickstart. See systemd-update-done.service(8).' \
|
||||
# See bug 1317709
|
||||
rm -f /boot/*-rescue*
|
||||
|
||||
# Disable network service here, as doing it in the services line
|
||||
# fails due to RHBZ #1369794
|
||||
/sbin/chkconfig network off
|
||||
|
||||
%end
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user