Skip to content
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

Require Go 1.22 for building the operator #3057

Merged
merged 1 commit into from
Jun 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions .chloggen/chore_upgrade-go-122.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: enhancement

# The name of the component, or a single word describing the area of concern, (e.g. collector, target allocator, auto-instrumentation, opamp, github action)
component: collector, target allocator, opamp

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Require Go 1.22 for building the operator

# One or more tracking issues related to the change
issues: [2757]

# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext:
10 changes: 5 additions & 5 deletions .github/workflows/publish-images.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ jobs:

- uses: actions/setup-go@v5
with:
go-version: '~1.21.3'
go-version: '~1.22.4'

- name: Unshallow
- name: Unshallow
run: git fetch --prune --unshallow

- name: Describe the current state
- name: Describe the current state
run: git describe --tags

- name: Set env vars for the job
Expand All @@ -41,15 +41,15 @@ jobs:
grep -v '\#' versions.txt | grep autoinstrumentation-nginx | awk -F= '{print "AUTO_INSTRUMENTATION_NGINX_VERSION="$2}' >> $GITHUB_ENV
echo "VERSION_DATE=$(date -u +'%Y-%m-%dT%H:%M:%SZ')" >> $GITHUB_ENV
echo "VERSION=$(git describe --tags | sed 's/^v//')" >> $GITHUB_ENV

- name: Build the binary for each supported architecture
run: |
for platform in $(echo $PLATFORMS | tr "," "\n"); do
arch=${platform#*/}
echo "Building manager for $arch"
make manager ARCH=$arch
done

- name: Docker meta
id: docker_meta
uses: docker/metadata-action@v5
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish-operator-opamp-bridge.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ jobs:

steps:
- uses: actions/checkout@v4

- uses: actions/setup-go@v5
with:
go-version: '~1.21.3'
go-version: '~1.22.4'

# TODO: We're currently not using this. Should we?
- name: Read version
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish-target-allocator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:

- uses: actions/setup-go@v5
with:
go-version: '~1.21.3'
go-version: '~1.22.4'

# TODO: We're currently not using this. Should we?
- name: Read version
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/open-telemetry/opentelemetry-operator

go 1.21.0
go 1.22.0

retract v1.51.0

Expand Down
4 changes: 2 additions & 2 deletions tests/e2e-openshift/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# The Dockerfile's resulting image is purpose-built for executing OpenTelemetry Operator e2e tests within the OpenShift release (https://github.com/openshift/release) using Prow CI.
# The Dockerfile's resulting image is purpose-built for executing OpenTelemetry Operator e2e tests within the OpenShift release (https://github.com/openshift/release) using Prow CI.

FROM golang:1.21
FROM golang:1.22

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically I don't need to make thing change here, but I thought it'd be good to be consistent.

# Copy the repository files
COPY . /tmp/opentelemetry-operator
Expand Down
2 changes: 1 addition & 1 deletion tests/instrumentation-e2e-apps/golang/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.21-alpine as builder
FROM golang:1.22-alpine as builder

COPY main.go .
RUN CGO_ENABLED=0 GOOS=linux GO111MODULE=on go build -o app main.go
Expand Down
Loading