Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/dependabot-plus-plus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- uses: actions/checkout@v7

- name: Install uv
uses: astral-sh/setup-uv@1c37ad07a6a961277cf70c0d37d6f313000f5884 # v10.3.0
uses: techcode-io/github-actions/setup-uv@setup-uv/v1

- name: Upgrade versions
id: upgrade
Expand All @@ -36,7 +36,7 @@ jobs:

- name: Create Pull Request
if: steps.upgrade.outputs.has_changes == 'true'
uses: peter-evans/create-pull-request@v8
uses: techcode-io/github-actions/create-pull-request@create-pull-request/v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/env-install/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ runs:
using: "composite"
steps:
- name: Install uv
uses: astral-sh/setup-uv@1c37ad07a6a961277cf70c0d37d6f313000f5884 #v10.3.0
uses: techcode-io/github-actions/setup-uv@setup-uv/v1

- name: Install dependencies
run: |
Expand Down
9 changes: 7 additions & 2 deletions src/etc/s6/boot/stage3
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,13 @@ foreground {
importas -D 16000 -u IGNITY_SERVICES_GRACETIME IGNITY_SERVICES_GRACETIME
# s6-svwait -t 0 waits forever: a grace time of 0 means do not wait
if { eltest ${IGNITY_SERVICES_GRACETIME} -gt 0 }
elglob SERVICES /run/ignity/services-state/*
foreground { s6-svwait -D -t ${IGNITY_SERVICES_GRACETIME} ${SERVICES} }
# No service: nothing to wait for, the pattern must not reach s6-svwait
elglob -0 SERVICES /run/ignity/services-state/*
foreground {
forx -p d { ${SERVICES} }
importas -ui d d
s6-svwait -D -t ${IGNITY_SERVICES_GRACETIME} ${d}
}
s6-sleep -m 200
}

Expand Down
6 changes: 6 additions & 0 deletions tests/test_boot.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,3 +173,9 @@ def test_accounts_never_duplicate_an_existing_id(image):
assert result.returncode == 0, result.stdout + result.stderr
assert "/accounts/passwd:0" in result.stdout
assert "/accounts/group:0" in result.stdout


def test_shutdown_without_services_is_clean(image):
result = run_in_container(image, "true")
assert result.returncode == 0
assert "s6-svwait" not in result.stderr
6 changes: 6 additions & 0 deletions tests/test_services.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,9 @@ def test_no_start_at_runtime_can_be_started(image):
cmd = "rm -f /run/ignity/services-state/no-start-at-runtime/down && s6-svc -u /run/ignity/services-state/no-start-at-runtime && sleep 1"
result = run_in_container(image, cmd)
assert "no-start service at runtime" in result.stdout


def test_shutdown_waits_for_services(image):
result = run_in_container(image, "true")
assert result.returncode == 0
assert "s6-svwait" not in result.stderr