Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main' into feature/udpate-gola…
Browse files Browse the repository at this point in the history
…ng-auto-bump

* upstream/main:
  docs: explain how to update the auto-bump (#368)
  • Loading branch information
v1v committed Dec 19, 2023
2 parents b9a8c21 + c7e673d commit 519cce3
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 10 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
name: bump-golang-1.20
name: bump-golang-previous

on:
workflow_dispatch:
Expand All @@ -19,7 +19,9 @@ jobs:
- uses: actions/checkout@v3
- uses: ./.github/workflows/bump-golang
with:
# NOTE: when a new golang version please update me with 1.<go-version-1>
branch: '1.20'
# NOTE: when a new golang version please update me with 1.<go-version-1>
go-minor: '1.20'
vaultUrl: ${{ secrets.VAULT_ADDR }}
vaultRoleId: ${{ secrets.VAULT_ROLE_ID }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/bump-golang.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:
- uses: ./.github/workflows/bump-golang
with:
branch: 'main'
# NOTE: when a new golang version please update me with 1.<go-version>
go-minor: '1.21'
vaultUrl: ${{ secrets.VAULT_ADDR }}
vaultRoleId: ${{ secrets.VAULT_ROLE_ID }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/opentelemetry.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
workflow_run:
workflows:
- bump-golang-main
- bump-golang-1.20
- bump-golang-previous
types: [completed]

jobs:
Expand Down
17 changes: 9 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -214,19 +214,20 @@ stateDiagram-v2

## Releasing images for a new Go version

With every new version of `go` we made a new branch with the name of the previous version to allow continue building the Docker images for the previous version of `go`. So if we are in go `1.19` and go `1.20` is released, we create a new branch `1.19`, the we update the `main` branch to install go `1.20`. Due to the changes in the Debian packages repositories, there is no guaranties that the Docker images for the previous version of `go` will continue to work after some time.
With every new version of `go` we made a new branch with the name of the previous version to allow us to continue building the Docker images for the previous version of `go`. So if we are in go `1.21` and go `1.22` is released, we create a new branch `1.21`, then we update the `main` branch to install go `1.22` as explained in the below steps:

1. Update the Go version in [.go-version](https://github.com/elastic/golang-crossbuild/blob/main/.go-version).
1. Update the Docker tag in
[Makefile.common](https://github.com/elastic/golang-crossbuild/blob/main/go1.10/Makefile.common#L5) and/or
[Makefile.common](https://github.com/elastic/golang-crossbuild/blob/main/go1.11/Makefile.common#L5) and/or
[Makefile.common](https://github.com/elastic/golang-crossbuild/blob/main/go1.12/Makefile.common#L5).
1. Update the Go version and SHA256 in the
[Dockerfile(s)](https://github.com/elastic/golang-crossbuild/blob/main/go1.10/base/Dockerfile#L19-L21).
The SHA256 must be obtained from <https://golang.org/dl/.>
[Makefile.common](https://github.com/elastic/golang-crossbuild/blob/main/go/Makefile.common#L5).
1. Run `.buildkite/bump-go-release-version.sh "$(cat .go-version)"`
1. Update the versions listed in this README.md.
1. Update the `go-minor` value in [bump-golang.yml](https://github.com/elastic/golang-crossbuild/blob/main/github/workflows/bump-golang.yml) with the new minor go version, i.e: `1.22`.
1. Update the `go-minor` and `branch` values in [bump-golang-previous.yml](https://github.com/elastic/golang-crossbuild/blob/main/github/workflows/bump-golang-previous.yml) with the old minor go version, i.e: `1.21`.
1. Commit the changes. `git add -u && git commit -m 'Update to Go 1.x.y'`.
1. Create a Pull Request with the description `'Update to Go 1.x.y'`.
1. When merging the PR then the automation will release those docker images.
1. When merging the PR, the automation will release those docker images.

**NOTE**: Due to the changes in the Debian packages repositories, there are no guarantees that the Docker images for the previous version of `go` will continue to work after some time.

## Packaging MacOS SDK

Expand Down

0 comments on commit 519cce3

Please sign in to comment.