Skip to content

Commit

Permalink
chore: unify setup-go and golang version (#201)
Browse files Browse the repository at this point in the history
Trying to fix #191

There are multiple go installations in all actions, so I would like to
make sure we use always the same version and to update it in a single
place

Signed-off-by: Oscar Cobles <oscar.cobles@eu.equinix.com>
  • Loading branch information
ocobles authored Sep 18, 2024
1 parent 7223b70 commit f0e184e
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 128 deletions.
2 changes: 1 addition & 1 deletion .github/actions/setup-tools/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ runs:
if: inputs.tools == 'all' || contains(inputs.tools, 'go')
uses: actions/setup-go@v5
with:
go-version: "1.22.x"
go-version-file: provider/go.mod
cache-dependency-path: |
provider/*.sum
upstream/*.sum
Expand Down
112 changes: 0 additions & 112 deletions .github/actions/upgrade-provider/action.yml

This file was deleted.

5 changes: 2 additions & 3 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ on:
inputs: {}
env:
DOTNETVERSION: 7.0.x
GOVERSION: 1.22.x
JAVAVERSION: "11"
NODEVERSION: 20.x
PYTHONVERSION: "3.9"
Expand All @@ -22,10 +21,10 @@ jobs:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Install go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
# The versions of golangci-lint and setup-go here cross-depend and need to update together.
go-version: 1.21
go-version-file: provider/go.mod
# Either this action or golangci-lint needs to disable the cache
cache: false
- name: disarm go:embed directives to enable lint
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ on:
env:
PROVIDER: equinix
DOTNETVERSION: 7.0.x
GOVERSION: 1.22.x
GRADLEVERSION: "7.6"
JAVAVERSION: "11"
NODEVERSION: 20.x
Expand Down Expand Up @@ -53,9 +52,9 @@ jobs:
- name: Unshallow clone for tags
run: git fetch --prune --unshallow --tags
- name: Install Go
uses: actions/setup-go@v2
uses: actions/setup-go@v5
with:
go-version: ${{ env.GOVERSION }}
go-version-file: provider/go.mod
- name: Install pulumictl
uses: jaxxstorm/action-install-gh-release@v1.10.0
with:
Expand Down Expand Up @@ -105,9 +104,9 @@ jobs:
- name: Unshallow clone for tags
run: git fetch --prune --unshallow --tags
- name: Install Go
uses: actions/setup-go@v2
uses: actions/setup-go@v5
with:
go-version: ${{ env.GOVERSION }}
go-version-file: provider/go.mod
- name: Install pulumictl
uses: jaxxstorm/action-install-gh-release@v1.10.0
with:
Expand Down
13 changes: 6 additions & 7 deletions .github/workflows/run-acceptance-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ env:
PROVIDER: equinix
PR_COMMIT_SHA: ${{ github.event.client_payload.pull_request.head.sha }}
DOTNETVERSION: 7.0.x
GOVERSION: 1.22.x
JAVAVERSION: "11"
NODEVERSION: 20.x
PYTHONVERSION: "3.9"
Expand All @@ -43,11 +42,11 @@ jobs:
- name: Unshallow clone for tags
run: git fetch --prune --unshallow --tags
- name: Install Go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
cache-dependency-path: |
sdk/go.sum
go-version: 1.21.x
go-version-file: provider/go.mod
- name: Install pulumictl
uses: jaxxstorm/action-install-gh-release@v1.10.0
with:
Expand Down Expand Up @@ -160,11 +159,11 @@ jobs:
- name: Unshallow clone for tags
run: git fetch --prune --unshallow --tags
- name: Install Go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
cache-dependency-path: |
sdk/go.sum
go-version: 1.21.x
go-version-file: provider/go.mod
- name: Install pulumictl
uses: jaxxstorm/action-install-gh-release@v1.10.0
with:
Expand Down Expand Up @@ -285,11 +284,11 @@ jobs:
- name: Unshallow clone for tags
run: git fetch --prune --unshallow --tags
- name: Install Go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
cache-dependency-path: |
sdk/go.sum
go-version: 1.21.x
go-version-file: provider/go.mod
- name: Install pulumictl
uses: jaxxstorm/action-install-gh-release@v1.10.0
with:
Expand Down

0 comments on commit f0e184e

Please sign in to comment.