Backport of fix version output for consul-cni into release/1.4.x#3832
Merged
hc-github-team-consul-core merged 1 commit intorelease/1.4.xfrom Mar 28, 2024
Conversation
cfb5337 to
0718ecd
Compare
tgross
approved these changes
Mar 28, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport
This PR is auto-generated from #3829 to be assessed for backporting due to the inclusion of the label backport/1.4.x.
The below text is copied from the body of the original PR.
The
consul-cniplugin emits "version unknown" because the CNI library'sPluginMainuses a global variable that isn't being set as part of our build process. Import thecontrol-plane/versionpackage so that we have an identical version in builds across both binaries.How I've tested this PR
Before:
After:
How I expect reviewers to test this PR
As above
Checklist
Tests addedn/aNote for reviewers: an alternative approach I considered was to "vendor" the
control-plane/versionpackage into theconsul-cniplugin. This seems to work but doesn't make a different in binary size, and makes for a second place folks would need to update in releases, so I opted for an import. The nice thing about this (maybe?) is that it also keeps the indirect dependencies up-to-date inconsul-cni. Happy to change approaches here though, if you'd like.Nomad fingerprints CNI binary versions to ensure that the node we place workloads onto can actually support the requested networking configuration, so we'll need to this for Nomad's transparent proxy support hashicorp/nomad#10628
Overview of commits