Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
|
/hold |
|
/approve |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: jcantrill, vparfonov The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
blocked by openshift/cluster-logging-operator#3482 where minio is missing |
|
/override ci/prow/clo-functional |
|
@jcantrill: Overrode contexts on behalf of jcantrill: ci/prow/clo-functional, ci/prow/cluster-logging-operator-e2e DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
New changes are detected. LGTM label has been removed. |
0c7e3ee to
2567d92
Compare
|
/retest |
Add git_commit field to Vector startup log showing the commit SHA the binary was built from. Uses three-tier fallback: 1. git rev-parse --short HEAD (local builds with full .git) 2. GIT_COMMIT environment variable (set by Makefile) 3. Direct .git file reading (Docker builds with minimal .git metadata) Include minimal .git metadata (~208KB) in Docker context: - .git/HEAD - .git/refs/heads - .git/packed-refs This enables git commit detection in all build scenarios: local dev, Docker builds, and CI/ART without requiring full git history. Changes: - build.rs: add git_short_hash() with three fallbacks, use optional constant - src/internal_events/process.rs: add git_commit field to startup log - src/lib.rs: handle Option<&str> in version string - Makefile: export GIT_COMMIT in build targets, add image target with platform detection - .dockerignore: allow minimal .git metadata Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2567d92 to
92a262c
Compare
|
@vparfonov: The following tests failed, say
Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
Summary
Add Git commit SHA to Vector startup log for build traceability. When Vector starts, it now logs the commit SHA it was built from, making it easy to identify which code version is running in dev, test, and production environments.
Example output:
Vector has started. debug="false" version="0.47.0" arch="x86_64" revision="" git_commit="8f50ca91d5"
Implementation
Uses a three-tier fallback approach to detect the commit in all build scenarios:
git rev-parse --short HEAD) — works for local dev builds with full.gitGIT_COMMITenvironment variable — set by Makefile'sbuildtarget.gitfile reading — reads.git/HEADand ref files for Docker/CI buildsIncludes minimal
.gitmetadata (~208KB) in Docker build context:.git/HEAD— pointer to current branch.git/refs/heads/— branch commit references.git/packed-refs— packed ref fallbackChanges
git_short_hash()with three fallbacks, optional constantgit_commitfield in startup logOption<&str>in version string with.unwrap_or("unknown")GIT_COMMITinbuild/build-offline, addmake imagetarget with macOS platform detection.gitmetadata with explanatory comment/assign @jcantrill