Skip to content

[14.5-stable] debug: skip upstream OpenSSH tests only on RISC-V - #7067

Merged
rene merged 1 commit into
lf-edge:14.5-stablefrom
shjala:fix/14.5-openssh-riscv-tests
Nov 9, 2026
Merged

rene merged 1 commit into
lf-edge:14.5-stablefrom
shjala:fix/14.5-openssh-riscv-tests

Conversation

@shjala

@shjala shjala commented Nov 9, 2026 •

Copy link
Copy Markdown
Member

Description

Skip the upstream OpenSSH make tests invocation only when TARGETARCH=riscv64, to unblock RISC-V publishing after #7049. OpenSSH 10.6p2 treats seccomp setup failures as fatal, while QEMU user-mode cannot install seccomp filters; the upstream connection tests therefore fail after successful compilation.

amd64 and arm64 continue to run the existing upstream test suite. Only RISC-V skips that step. Our SSHole/public-key/SFTP regression, production authentication checks and debug Go test stage remain unchanged. OpenSSH source and the production seccomp sandbox are unchanged.

Refresh the installer debug-image pin. No workflow changes, VM infrastructure or new scripts.

How to test and validate this PR

  • Docker hash consistency and git diff --check pass. Independently compared the installer pin with linuxkit pkg show-tag pkg/debug, since the branch's checker excludes that Dockerfile.
  • Confirm the RISC-V publish job gets past the OpenSSH install step without invoking the upstream suite, while amd64 and arm64 still invoke make tests.
  • Existing amd64/arm64 debug test stages continue to exercise our SSH regression and production authentication settings.
  • No fresh full local image build or physical-device validation is claimed.

Changelog notes

Unblock RISC-V image publishing by skipping upstream OpenSSH tests only on RISC-V.

PR Backports

Master #7046 likewise uses Alpine packages without this invocation.

Checklist

  • I've provided a proper description
  • I've added the proper documentation (validation instructions)
  • I've tested my PR on amd64 device
  • I've tested my PR on arm64 device
  • I've written the test verification instructions
  • I've set the proper labels to this PR
  • I've checked the boxes above, or provided validation limitations

@github-actions

github-actions Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Reviewing this PR

  • Read the diff and changed files
  • Review workflow, Dockerfile, and shell scripts
  • Post inline review comments

View job run

@shjala
shjala force-pushed the fix/14.5-openssh-riscv-tests branch from 852810f to 4ec52cc Compare November 9, 2026 12:46
@github-actions

github-actions Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @shjala's task in 3m 18s —— View job


Code review

  • Read the diff and changed files
  • Review workflow, Dockerfile, and shell scripts
  • Post inline review comments

I reviewed the 6 changed files. One blocking issue, posted inline; details below.

Blocking

tools/test-openssh-riscv.sh:29 — docker build --network=none will fail the build.
The openssh-build target requires network (eve-alpine-deploy.sh/apk add, plus ADD of musl, lshw, hexedit and the OpenSSH tarball from external URLs). Neither CI path sets OPENSSH_TEST_IMAGE (the smoke workflow doesn't, and in publish.yml the test step runs before "Build packages"), so both take the build path and will fail at the first networked step. The PR's local smoke test only exercised the OPENSSH_TEST_IMAGE=<prebuilt> path, which skips this block — so the regression wasn't caught. Removing --network=none fixes it; the test VM itself is already isolated via QEMU -nic none. See inline comment.

Minor (non-blocking, no change required)

  • .github/workflows/openssh-riscv.yml:35 — OPENSSH_TEST_TIMEOUT: 5m is tight for a TCG-emulated RISC-V boot + make t-exec LTESTS=connect + the full openssh.sh regression. If the runner is slower than the author's workstation this could be a flaky timeout; worth watching once the build path above is fixed.
  • tools/test-openssh-riscv.sh:17 — the [[ -r "$firmware" ]] guard exits silently under set -e if the opensbi firmware isn't at the default path; a short error message would make CI failures easier to diagnose.

Checked and fine

  • pkg/debug/tests/openssh-riscv-init.sh — correct set -eu + EXIT trap emitting RISCV_OPENSSH_TEST_RESULT=$result; keeps the production seccomp sandbox assertion (grep '^#define SANDBOX_SECCOMP_FILTER 1') and the password/kbd-interactive "no" checks. /out is already fully populated by eve-alpine-deploy.sh in the openssh-build stage, so the install-nokeys + chroot flow works.
  • tools/test-openssh-riscv.sh — kernel archive is checksum-pinned; pipefail + the final grep -qx 'RISCV_OPENSSH_TEST_RESULT=0' correctly catch the "QEMU exits 0 after a guest failure" case.
  • pkg/debug/Dockerfile — RISC-V correctly excluded from the in-build make tests; amd64/arm64 unchanged.
  • pkg/installer/Dockerfile / publish.yml — debug pin refresh and the guarded (matrix.arch == 'riscv64') publish steps look consistent.

Comment thread tools/test-openssh-riscv.sh Resolved
@shjala
shjala force-pushed the fix/14.5-openssh-riscv-tests branch from 4ec52cc to a8d98f5 Compare November 9, 2026 13:48
@shjala shjala changed the title [14.5-stable] debug: fix RISC-V OpenSSH publish tests [14.5-stable] debug: remove upstream OpenSSH tests from package build Nov 9, 2026
@github-actions

github-actions Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @shjala's task in 1m 46s —— View job


Code review

  • Read the diff and changed files
  • Verify no leftover references to the removed test invocation
  • Check debug image pin consumers
  • Post review

The PR has been re-scoped since the previous review to a minimal, self-contained change: the upstream make tests invocation is dropped from pkg/debug/Dockerfile and the debug-image pin in pkg/installer/Dockerfile is refreshed. The test-script / workflow files that the earlier --network=none blocking comment targeted are no longer part of this PR, so that concern is moot.

Findings

  • pkg/debug/Dockerfile — removing make tests also drops the upstream suite on amd64/arm64, not just RISC-V. Acknowledged in the description and matches 13.4-stable; non-blocking. Comment posted inline.
  • pkg/installer/Dockerfile — the new pin could not be verified locally (linuxkit is unavailable here). Comment posted inline asking CI to confirm the installer build resolves the new tag, since the PR notes the branch's pin-checker excludes this Dockerfile.

I confirmed there are no remaining make tests references under pkg/debug/, and that pkg/installer/Dockerfile is the only build consumer of the lfedge/eve-debug pin (other matches are docs/tests using latest or stale hashes).

Overall: low-risk, clean change consistent with the stated goal. No blocking issues.

OpenSSH 10.6p2 aborts when seccomp setup fails under QEMU user-mode, causing the upstream connection tests to block RISC-V publishing after lf-edge#7049. Skip that upstream test step only for the riscv64 target; retain it for amd64 and arm64.

Keep the SSHole regression and debug test stage unchanged. Refresh the installer debug-image pin. No OpenSSH source or production sandbox configuration changes.

Signed-off-by: Shahriyar Jalayeri <shahriyar@posteo.de>
@shjala
shjala force-pushed the fix/14.5-openssh-riscv-tests branch from a8d98f5 to b19c5b0 Compare November 9, 2026 13:51
@shjala shjala changed the title [14.5-stable] debug: remove upstream OpenSSH tests from package build [14.5-stable] debug: skip upstream OpenSSH tests only on RISC-V Nov 9, 2026
Comment thread pkg/debug/Dockerfile Resolved
Comment thread pkg/installer/Dockerfile Resolved
@github-actions

github-actions Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @shjala's task in 1m 53s —— View job


Code review

  • Read the diff and changed files
  • Review the Dockerfile make tests guard
  • Verify the installer debug-image pin
  • Post review

This PR has been substantially simplified since my earlier review. The RISC-V test-harness approach (tools/test-openssh-riscv.sh, .github/workflows/openssh-riscv.yml, pkg/debug/tests/openssh-riscv-init.sh) is gone, so the previously-blocking --network=none finding no longer applies. The current diff is just the two Dockerfile changes, and it's clean.

No blocking issues

pkg/debug/Dockerfile — the make tests guard is correct.

  • TARGETARCH is a BuildKit-provided automatic ARG; it's declared in-scope right before use (line 99) and populated by linuxkit's buildx --platform linux/<arch> invocation.
  • An empty/unset TARGETARCH falls through to running make tests, so amd64/arm64 behavior is unchanged — only riscv64 skips the upstream suite, as intended.
  • Binary installation into /out (line 105+) is unaffected by the skip.

One note (non-blocking)

  • Installer debug pin — the bump to c655bb06… is required by the pkg/debug change, but your description notes the branch's hash checker excludes this FROM, so nothing in CI validates it. Worth a final confirm against linuxkit pkg show-tag pkg/debug so the installer doesn't silently build against the old (still-testing-on-riscv) debug image. Posted inline.

Trade-off worth acknowledging (not a change request)

Skipping make tests wholesale on riscv64 means the upstream OpenSSH self-tests no longer gate the riscv64 build at all — a future riscv-specific build/runtime regression in OpenSSH wouldn't be caught here. That's the accepted cost of unblocking publishing, and your SSHole/public-key/SFTP regression plus the production seccomp sandbox assertion still run on amd64/arm64.

Comment thread pkg/installer/Dockerfile
RUN cp "/usr/local/my-installer/target/$CARGO_BUILD_TARGET/release/installer" /usr/local/my-installer/target/installer

FROM lfedge/eve-debug:65486b943c4d12ad05e9aa22ace57e4d1cf4adaa AS debug
FROM lfedge/eve-debug:c655bb06a9e48d41a29a2cdb9cffc381fc8f4944 AS debug

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The debug pin bump is required because pkg/debug/Dockerfile changed. Per your PR description the branch's hash-consistency checker excludes this FROM, so nothing in CI validates that c655bb06a9e48d41a29a2cdb9cffc381fc8f4944 equals the tag the current pkg/debug source produces. Please double-check it against linuxkit pkg show-tag pkg/debug on this branch — a stale pin here would silently build the installer against the old debug image (the one that still runs make tests on riscv64), defeating the fix.

@rene
rene merged commit f60115e into lf-edge:14.5-stable Nov 9, 2026
41 of 46 checks passed
@codecov

codecov Bot commented Nov 9, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 32.18%. Comparing base (272ffae) to head (b19c5b0).
⚠️ Report is 309 commits behind head on 14.5-stable.

Additional details and impacted files
@@               Coverage Diff               @@
##           14.5-stable    #7067      +/-   ##
===============================================
+ Coverage        24.97%   32.18%   +7.20%     
===============================================
  Files                8       14       +6     
  Lines             1185     2663    +1478     
===============================================
+ Hits               296      857     +561     
- Misses             820     1806     +986     
+ Partials            69        0      -69     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants