Accepting request 962210 from home:favogt:combustion
- Remove /var/lib/YaST2/reconfig_system if a config was provided: * ignition-remove-reconfig_system.service OBS-URL: https://build.opensuse.org/request/show/962210 OBS-URL: https://build.opensuse.org/package/show/devel:kubic:ignition/ignition?expand=0&rev=86
This commit is contained in:
parent
5ec6f3f99d
commit
c489446194
21
ignition-remove-reconfig_system.service
Normal file
21
ignition-remove-reconfig_system.service
Normal file
@ -0,0 +1,21 @@
|
||||
[Unit]
|
||||
Description=Disable firstboot wizard if ignition ran
|
||||
|
||||
# Make sure ignition completed
|
||||
After=ignition-complete.target
|
||||
# Don't race with combustion
|
||||
After=combustion.service
|
||||
|
||||
# Make sure /sysroot/etc and var are available
|
||||
After=initrd-parse-etc.service
|
||||
RequiresMountsFor=/sysroot/etc
|
||||
RequiresMountsFor=/sysroot/var
|
||||
|
||||
ConditionPathExists=/sysroot/etc/.ignition-result.json
|
||||
ConditionPathExists=/sysroot/var/lib/YaST2/reconfig_system
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
RemainAfterExit=yes
|
||||
# Use grep to avoid pulling in jq
|
||||
ExecStart=/bin/sh -ec 'if grep -q "\\"userConfigProvided\\":.*true" /sysroot/etc/.ignition-result.json; then rm /sysroot/var/lib/YaST2/reconfig_system; fi'
|
@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Mar 4 10:46:21 UTC 2022 - Fabian Vogt <fvogt@suse.com>
|
||||
|
||||
- Remove /var/lib/YaST2/reconfig_system if a config was provided:
|
||||
* ignition-remove-reconfig_system.service
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Mar 4 10:23:10 UTC 2022 - Fabian Vogt <fvogt@suse.com>
|
||||
|
||||
|
@ -35,6 +35,7 @@ Source9: ignition-setup-user.service
|
||||
Source10: ignition-enable-network.service
|
||||
Source11: ignition-enable-network.sh
|
||||
Source12: ignition-kargs-helper
|
||||
Source13: ignition-remove-reconfig_system.service
|
||||
Source20: ignition-userconfig-timeout.conf
|
||||
Source21: ignition-userconfig-timeout-arm.conf
|
||||
Patch2: 0002-allow-multiple-mounts-of-same-device.patch
|
||||
@ -82,12 +83,11 @@ GRUB2 configuration which sets ignition.firstboot based on
|
||||
which creates firstboot_happened after the first boot.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch2 -p1
|
||||
%autosetup -p1
|
||||
|
||||
mkdir dracut/30ignition-microos grub systemd_suse
|
||||
chmod +x %{SOURCE3} %{SOURCE4} %{SOURCE8} %{SOURCE12}
|
||||
cp %{SOURCE1} %{SOURCE3} %{SOURCE4} %{SOURCE8} %{SOURCE9} %{SOURCE10} %{SOURCE11} dracut/30ignition-microos/
|
||||
cp %{SOURCE1} %{SOURCE3} %{SOURCE4} %{SOURCE8} %{SOURCE9} %{SOURCE10} %{SOURCE11} %{SOURCE13} dracut/30ignition-microos/
|
||||
%ifarch aarch64 %{arm}
|
||||
cp %{SOURCE21} dracut/30ignition-microos/ignition-userconfig-timeout.conf
|
||||
%else
|
||||
|
@ -30,6 +30,7 @@ install() {
|
||||
inst_script "$moddir/ignition-setup-user.sh" \
|
||||
"/usr/sbin/ignition-setup-user"
|
||||
inst_multiple awk systemd-detect-virt
|
||||
install_ignition_unit ignition-remove-reconfig_system.service initrd.target
|
||||
install_ignition_unit ignition-setup-user.service
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user