File tree Expand file tree Collapse file tree 3 files changed +19
-12
lines changed Expand file tree Collapse file tree 3 files changed +19
-12
lines changed Original file line number Diff line number Diff line change 1+ # A simple nushell "library" for the
2+
3+ # This is a workaround for what must be a systemd bug
4+ # that seems to have appeared in C10S
5+ # TODO diagnose and fill in here
6+ export def reboot [] {
7+ # Sometimes systemd daemons are still running old binaries and response "Access denied" when send reboot request
8+ # Force a full sync before reboot
9+ sync
10+ # Allow more delay for bootc to settle
11+ sleep 30sec
12+
13+ tmt-reboot
14+ }
Original file line number Diff line number Diff line change 11use std assert
22use tap .nu
3+ use bootc_testlib .nu
34
45def initial_build [] {
56 tap begin " factory reset test"
@@ -41,16 +42,7 @@ def initial_build [] {
4142 # nu's cp doesn't have -T
4243 /usr/bin/cp -r -T $workdir_root $" ($new_stateroot_path )/($workdir_root )"
4344
44- # Check reset status before reboot
45- RUST_LOG =trace bootc status
46-
47- # Sometimes systemd daemons are still running old binaries and response "Access denied" when send reboot request
48- # Force a full sync before reboot
49- sync
50- # Allow more delay for bootc to settle
51- sleep 30sec
52-
53- tmt-reboot
45+ bootc_testlib reboot
5446}
5547
5648# The second boot; verify we're in the factory reset deployment
Original file line number Diff line number Diff line change 11# Verify that bootc usroverlay works
22use std assert
33use tap .nu
4+ use bootc_testlib .nu
45
56bootc status
67
@@ -12,8 +13,8 @@ def initial_run [] {
1213 bootc usroverlay
1314 let is_writable = (do - i { /bin/test -w /usr } | complete | get exit_code ) == 0
1415 assert ($is_writable )
15-
16- tmt- reboot
16+
17+ bootc_testlib reboot
1718}
1819
1920# The second boot; verify we're in the derived image
You can’t perform that action at this time.
0 commit comments