You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit addde3e
Browse filesBrowse the repository at this point in the historyBrowse files
# list-unit-files returns status 1 for an empty inventory without diagnostics.
106
+
if((inventory_status !=0));then
107
+
[[ $inventory_kind== list-unit-files &&$inventory_status== 1 &&-z$inventory ]] || die 'foreign systemd unit inventory could not be inspected'
108
+
fi
109
+
whileread -r unit _;do
110
+
case$unitin
111
+
ci-fleet-deployer*|ci-fleet-health*|ci-fleet-cleanup*|ci-fleet-reconcile*|ci-fleet-drift*|ci-fleet-status-receiver*|actions.runner*) die 'another ci-fleet host role is present' ;;
if [[ ${FAKE_TESTER_UNIT_INVENTORY_FAIL:-0} == 1 ]]; then printf 'inventory inspection failed\n' >&2; exit "${FAKE_TESTER_UNIT_INVENTORY_FAILURE_CODE:-7}"; fi
35
+
if [[ ${FAKE_TESTER_EMPTY_UNIT_INVENTORY:-0} == 1 ]]; then
36
+
[[ $1 != list-unit-files ]] || exit 1
37
+
exit 0
38
+
fi
39
+
if [[ $1 == list-unit-files && " $* " == *'ci-fleet-'* && -z ${FAKE_TESTER_FOREIGN_UNIT:-} ]]; then exit 1; fi
40
+
printf 'unrelated.service enabled\n'
41
+
printf 'ci-fleet-tester-health.service enabled\n'
34
42
if [[ -n ${FAKE_TESTER_FOREIGN_UNIT:-} && ${FAKE_TESTER_FOREIGN_UNIT_KIND:-$1} == "$1" ]]; then printf '%s enabled\n' "$FAKE_TESTER_FOREIGN_UNIT"; fi
# list-unit-files returns status 1 for an empty inventory without diagnostics.
454
+
if((inventory_status !=0));then
455
+
[[ $inventory_kind== list-unit-files &&$inventory_status== 1 &&-z$inventory ]] || die 'foreign systemd unit inventory could not be inspected'
456
+
fi
457
+
whileread -r unit _;do
458
+
case$unitin
459
+
ci-fleet-deployer*|ci-fleet-health*|ci-fleet-cleanup*|ci-fleet-reconcile*|ci-fleet-drift*|ci-fleet-status-receiver*|actions.runner*) die 'another ci-fleet host role is present' ;;
0 commit comments