-
Notifications
You must be signed in to change notification settings - Fork 153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update core version during build #1379
Conversation
During build we need to also update the core version file, otherwise, the internal metrics show "latest" instead of the real version.
Approved by accident. Not sure this solution will solve the problem |
Makefile
Outdated
@@ -37,10 +37,12 @@ LINT=golangci-lint | |||
MISSPELL=misspell -error | |||
MISSPELL_CORRECTION=misspell -w | |||
|
|||
BUILD_INFO_IMPORT_PATH=github.com/signalfx/splunk-otel-collector/internal/version | |||
BUILD_INFO_IMPORT_PATH=go.opentelemetry.io/collector/internal/version |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we keep github.com/signalfx/splunk-otel-collector/internal/version
, otherwise how will the version get set for https://github.com/signalfx/splunk-otel-collector/blob/main/cmd/otelcol/main.go#L83?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right. I think it should be
BUILD_INFO_IMPORT_PATH=github.com/signalfx/splunk-otel-collector/internal/version
BUILD_INFO_IMPORT_PATH_CORE=go.opentelemetry.io/collector/internal/version
I didn't notice that it was replacement for splunk distro. Now it makes sense why it didn't work before
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right. I think it should be
BUILD_INFO_IMPORT_PATH=github.com/signalfx/splunk-otel-collector/internal/version BUILD_INFO_IMPORT_PATH_CORE=go.opentelemetry.io/collector/internal/version
I didn't notice that it was replacement for splunk distro. Now it makes sense why it didn't work before
Sorry, my bad, it was actually pointing to the version in our distro when I tested it but for the PR somehow I replaced that line, thanks for catching that!
During build we need to also update the core version file, otherwise, the internal metrics show "latest" instead of the real version.