Skip to content

feat: add s390x support to install-cli.sh#936

Merged
dangrondahl merged 1 commit into
mainfrom
feat-install-cli-s390x
Jun 4, 2026
Merged

feat: add s390x support to install-cli.sh#936
dangrondahl merged 1 commit into
mainfrom
feat-install-cli-s390x

Conversation

@dangrondahl
Copy link
Copy Markdown
Contributor

@dangrondahl dangrondahl commented Jun 4, 2026

Summary

  • Map the s390x machine type to the s390x release asset in install-cli.sh
  • Update the unsupported-arch error message to list s390x alongside amd64 and arm64

The linux/s390x build target was added in 4acd31e, but the install script still rejected the architecture, forcing s390x users to download the tarball manually.

Test plan

  • Run install-cli.sh on a linux/s390x host and verify it downloads kosli_<version>_linux_s390x.tar.gz and installs successfully
  • Confirm existing amd64 / arm64 / darwin / windows paths still work

Map the s390x machine type to the s390x release asset so the install
script works on linux/s390x hosts. The linux/s390x build target was
added in 4acd31e but install-cli.sh still rejected the architecture.
@claude
Copy link
Copy Markdown
Contributor

claude Bot commented Jun 4, 2026

Claude finished @dangrondahl's task in 1m 33s —— View job


Review of PR #936: feat: add s390x support to install-cli.sh

  • Run static analysis checks
  • Review code changes
  • Post review feedback

Static Analysis

All checks pass:

  • go build ./... — clean
  • go vet ./... — clean
  • go mod tidy — no drift

(Expected since this PR only touches a shell script, but good to confirm nothing else drifted.)

Code Review

This PR looks good to merge. The change is minimal, correct, and follows the existing patterns exactly.

What it does right:

  • The new s390x) case block at line 153–156 mirrors the structure of the amd64 and arm64 blocks — same pattern, same debug message style.
  • The error message update (line 159) correctly lists all three supported architectures.
  • Verified that s390x is already a GoReleaser build target (added in 4acd31e, PR feat: add linux/s390x build target to release distribution #930) and is correctly excluded from darwin and windows builds — so the install script will find a matching kosli_<version>_linux_s390x.tar.gz asset for Linux-only installs.

No issues found — no bugs, no edge cases missed, no security concerns. The uname -m value on s390x systems is literally s390x, so the single-value case match is correct (unlike amd64/arm64 which need multiple aliases).

@dangrondahl
Copy link
Copy Markdown
Contributor Author

Tested install of v2.24.2 across all release targets:

Target Method Result
linux/s390x Docker + qemu emulation, full install install succeeded, kosli version returned v2.24.2 ✅
linux/amd64 Docker + qemu emulation, full install install succeeded, kosli version returned v2.24.2 ✅
linux/arm64 Docker (native on Apple Silicon), full install install succeeded, kosli version returned v2.24.2 ✅
darwin/amd64 URL HEAD check 200 ✅
darwin/arm64 URL HEAD check 200 ✅
windows/amd64 URL HEAD check 200 ✅

Darwin/Windows aren't containerisable on macOS, but this patch only touches the Linux arch-detection branch, so the other OS paths are unchanged from main — the URL checks confirm the release assets they target exist.

@dangrondahl
Copy link
Copy Markdown
Contributor Author

Note: I considered adding s390x coverage to install-script-tests.yml, but GitHub doesn't offer s390x runners and emulating it via qemu in CI felt heavier than the marginal value — the s390x logic is a single extra case arm. Leaving it uncovered for now.

@dangrondahl dangrondahl enabled auto-merge (squash) June 4, 2026 10:45
@dangrondahl dangrondahl merged commit d8c9698 into main Jun 4, 2026
38 checks passed
@dangrondahl dangrondahl deleted the feat-install-cli-s390x branch June 4, 2026 10:48
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