8000 e2e: run extracted FIPS binaries in a container of the operator image by Slach · Pull Request #2175 · Altinity/clickhouse-operator · GitHub
[go: up one dir, main page]

Skip to content

e2e: run extracted FIPS binaries in a container of the operator image - #2175

Open
Slach wants to merge 5 commits into
0.28.0from
e2e-fips-in-container
Open

Slach wants to merge 5 commits into
0.28.0from
e2e-fips-in-container

Conversation

@Slach
@Slach Slach commented Nov 27, 2026
Copy link
Copy Markdown
Collaborator

The FIPS e2e tests (030001, 030011, 030015, 030017) copied clickhouse-operator and metrics-exporter out of the image and ran them on the host. That works only on a Linux amd64 host.

Changes in tests/e2e/steps_fips.py:

  • fips_binary_argv runs an extracted binary in a container of the operator image, on the host network, with the directories it reads mounted at the same paths.
  • GODEBUG goes to the container only. The image sets GODEBUG=fips140=off, so it is emptied unless the test sets it. The docker CLI itself panics under fips140=only, so it is not given that env.
  • The .go.fipsinfo offset is read in Python instead of readelf.
  • A failed TLS probe shows the binary output.

Tested locally on macOS (OrbStack, --native): 030001, 030008, 030011, 030015, 030017 pass.

🤖 Generated with Claude Code

The FIPS tests copied clickhouse-operator and metrics-exporter out of the
image and ran them on the host. That works only on a Linux amd64 host.
They now run in a container of the same image, on the host network, with
the directories they read mounted at the same paths, so the tests pass on
macOS too. GODEBUG goes to the container only: the image sets
GODEBUG=fips140=off, and the docker CLI itself panics under
fips140=only. The .go.fipsinfo offset is read in Python instead of readelf.

Co-Authored-By: Claude Opus 5.5 <noreply
8000
@anthropic.com>
@Slach
Slach requested review from Elmo33 and alex-zaitsev November 27, 2026 12:46
Slach and others added 3 commits November 27, 2026 16:51
Under a parallel run the first output line was not always the header, so
the header 'name' became a pod name. Use --no-headers and keep only lines
that can be names.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Slach added a commit that referenced this pull request Nov 27, 2026
- Build from a git worktree: GIT_SHA is a build arg, .git is out of the
  docker context. #2176
- FIPS e2e run the extracted binaries in a container of the operator image,
  so they pass on macOS; get_obj_names skips stray shell lines.
  #2175

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Slach added a commit that referenced this pull request Nov 27, 2026
Also proposed in #2175.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The image runs as nobody and cannot read the 0700 temp dir of the test,
so the binary failed with permission denied on Linux runners.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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.

1 participant

0