Skip to content

Commit

Permalink
Move to conditional networking
Browse files Browse the repository at this point in the history
We have all the piece in place now to move to conditional networking. So
let's drop the firstboot kargs, as well as
coreos-liveiso-network-kargs.service, which is no longer needed (i.e.
the live ISO will now enable initrd networking as required given the
embedded Ignition config).

Fixes: coreos/fedora-coreos-tracker#443
  • Loading branch information
jlebon committed May 26, 2020
1 parent 608cb48 commit 849061f
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 82 deletions.
7 changes: 3 additions & 4 deletions image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,9 @@ extra-kargs:
# https://fedoraproject.org/wiki/Changes/CGroupsV2
- systemd.unified_cgroup_hierarchy=0

# Kernel arguments to be used on first-boot.
ignition-network-kcmdline:
- 'rd.neednet=1'
- 'ip=dhcp,dhcp6'
# Disable networking by default on firstboot. We can drop this once cosa stops
# defaulting to `ip=dhcp,dhcp6 rd.neednet=1` when it doesn't see this key.
ignition-network-kcmdline: []

# Optional remote by which to prefix the deployed OSTree ref
ostree-remote: fedora
Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ add_requires sysroot.mount initrd-root-fs.target
add_requires sysroot-etc.mount initrd-root-fs.target
add_requires sysroot-var.mount initrd-root-fs.target

add_requires coreos-liveiso-network-kargs.service initrd.target
add_requires coreos-liveiso-reconfigure-nm-wait-online.service initrd.target

mkdir -p "${UNIT_DIR}/ostree-prepare-root.service.d"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,6 @@ install() {
inst_simple "$moddir/writable.mount" \
"$systemdsystemunitdir/writable.mount"

inst_simple "$moddir/coreos-liveiso-network-kargs.sh" \
"/usr/sbin/coreos-liveiso-network-kargs"

inst_simple "$moddir/coreos-liveiso-network-kargs.service" \
"$systemdsystemunitdir/coreos-liveiso-network-kargs.service"

inst_simple "$moddir/coreos-liveiso-reconfigure-nm-wait-online.service" \
"$systemdsystemunitdir/coreos-liveiso-reconfigure-nm-wait-online.service"
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@
[Unit]
Description=CoreOS Live ISO virtio success
Documentation=https://github.com/coreos/fedora-coreos-config
# Only run on the Live ISO, and only if there's no Ignition config;
# the second bits here invert the conditionals in coreos-liveiso-network-kargs.service.
# Only run on the Live ISO, and only if there's no Ignition config
ConditionKernelCommandLine=coreos.liveiso
ConditionPathExists=!/config.ign
ConditionVirtualization=|kvm
Expand Down

0 comments on commit 849061f

Please sign in to comment.