Skip to content

Commit

Permalink
Merge branch 'main' into add-aws
Browse files Browse the repository at this point in the history
Signed-off-by: Jorge Turrado Ferrero <[email protected]>
  • Loading branch information
JorTurFer authored Dec 27, 2023
2 parents 0e6a3f3 + da70147 commit 12cc370
Show file tree
Hide file tree
Showing 829 changed files with 31,149 additions and 7,422 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Licensed under the MIT License. See https://go.microsoft.com/fwlink/?linkid=2090316 for license information.
#-------------------------------------------------------------------------------------------------------------

FROM golang:1.20.8
FROM golang:1.21.5

# Avoid warnings by switching to noninteractive
ENV DEBIAN_FRONTEND=noninteractive
Expand Down
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/3_bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ body:
label: KEDA Version
description: What version of KEDA that are you running?
options:
- "2.12.1"
- "2.12.0"
- "2.11.2"
- "2.11.1"
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/4_release_tracker.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ We aim to release this release in the week of <week range, example March 27-31>.

- [ ] Prepare changelog
- [ ] [Welcome message supported versions](https://github.com/kedacore/keda/blob/main/pkg/util/welcome.go#L29-L30) are up-to-date
- [ ] Add the new version to GitHub Bug report template
- [ ] Add the new version to [GitHub Bug report](https://github.com/kedacore/keda/blob/main/.github/ISSUE_TEMPLATE/3_bug_report.yml) template
- [ ] Create KEDA release
- [ ] Publish new documentation version
- [ ] Setup continuous container scanning with Snyk
Expand Down
2 changes: 2 additions & 0 deletions .github/cherry-pick-bot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
enabled: true
preservePullRequestTitle: true
6 changes: 3 additions & 3 deletions .github/workflows/fossa.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5
with:
go-version: "1.20"
go-version: "1.21"
- run: go version
- name: Get branch name
id: branch-name
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/main-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@ on:
jobs:
build:
name: build
runs-on: ubuntu-latest
runs-on: ARM64
permissions:
contents: read
packages: write
id-token: write # needed for signing the images with GitHub OIDC Token **not production ready**

# keda-tools is built from github.com/test-tools/tools/Dockerfile
container: ghcr.io/kedacore/keda-tools:1.20.8
container: ghcr.io/kedacore/keda-tools:1.21.5
steps:
- name: Check out code
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
with:
fetch-depth: 1

Expand All @@ -41,7 +41,7 @@ jobs:
key: ${{ runner.os }}-go-build-cache-${{ hashFiles('**/go.sum') }}

- name: Go modules sync
run: go mod tidy -compat=1.20
run: go mod tidy -compat=1.21

- name: Test
run: make test
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/pr-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
image_tag: "pr-${{ steps.parser.outputs.pr_num }}-${{ steps.parser.outputs.commit_sha }}"
commit_sha: ${{ steps.parser.outputs.commit_sha }}
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4

- uses: tspascoal/get-user-teams-membership@v2
id: checkUserMember
Expand All @@ -36,7 +36,7 @@ jobs:

- name: Add label to skip e2e test
if: ${{ startsWith(github.event.comment.body,'/skip-e2e') && steps.checkUserMember.outputs.isTeamMember == 'true' }}
uses: actions/github-script@d7906e4ad0b1822421a7e6a35d5ca353c962f410 # v6
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7
with:
github-token: ${{ secrets.GH_AUTOMATION_PAT }}
script: |
Expand Down Expand Up @@ -68,7 +68,7 @@ jobs:
needs: triage
runs-on: ubuntu-latest
name: Build images
container: ghcr.io/kedacore/keda-tools:1.20.8
container: ghcr.io/kedacore/keda-tools:1.21.5
if: needs.triage.outputs.run-e2e == 'true'
steps:
- name: Set status in-progress
Expand All @@ -80,7 +80,7 @@ jobs:
status: in_progress
details_url: https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}

- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4

- name: Register workspace path
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
Expand Down Expand Up @@ -112,7 +112,7 @@ jobs:
needs: [triage, build-test-images]
runs-on: e2e
name: Execute e2e tests
container: ghcr.io/kedacore/keda-tools:1.20.8
container: ghcr.io/kedacore/keda-tools:1.21.5
if: needs.triage.outputs.run-e2e == 'true'
steps:
- name: Set status in-progress
Expand All @@ -124,7 +124,7 @@ jobs:
status: in_progress
details_url: https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}

- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4

- name: Register workspace path
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
Expand Down Expand Up @@ -218,7 +218,7 @@ jobs:
details_url: https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}

- name: Upload test logs
uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 # v3
uses: actions/upload-artifact@c7d193f32edcb7bfad88892161225aeda64e9392 # v4
with:
name: e2e-test-logs
path: '${{ github.workspace }}/tests/**/*.log'
Expand Down
22 changes: 11 additions & 11 deletions .github/workflows/pr-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
validate:
name: validate - ${{ matrix.name }}
runs-on: ${{ matrix.runner }}
container: ghcr.io/kedacore/keda-tools:1.20.8
container: ghcr.io/kedacore/keda-tools:1.21.5
strategy:
matrix:
include:
Expand All @@ -21,7 +21,7 @@ jobs:
steps:

- name: Check out code
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
with:
fetch-depth: 1

Expand Down Expand Up @@ -50,7 +50,7 @@ jobs:
key: ${{ runner.os }}-go-build-cache-${{ hashFiles('**/go.sum') }}

- name: Go modules sync
run: go mod tidy -compat=1.20
run: go mod tidy -compat=1.21

- name: Verify generated Clientset is up to date
run: make clientset-verify
Expand All @@ -73,7 +73,7 @@ jobs:
validate-dockerfiles:
name: validate-dockerfiles - ${{ matrix.name }}
runs-on: ${{ matrix.runner }}
container: ghcr.io/kedacore/keda-tools:1.20.8
container: ghcr.io/kedacore/keda-tools:1.21.5
strategy:
matrix:
include:
Expand All @@ -83,7 +83,7 @@ jobs:
name: amd64
steps:
- name: Check out code
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
with:
fetch-depth: 1

Expand All @@ -104,7 +104,7 @@ jobs:
validate-dev-container:
name: Validate dev-container - ${{ matrix.name }}
runs-on: ${{ matrix.runner }}
container: ghcr.io/kedacore/keda-tools:1.20.8
container: ghcr.io/kedacore/keda-tools:1.21.5
strategy:
matrix:
include:
Expand All @@ -113,7 +113,7 @@ jobs:
- runner: ubuntu-latest
name: amd64
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4

- name: Register workspace path
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
Expand All @@ -133,13 +133,13 @@ jobs:
name: Static Checks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 # v4.7.1
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5.0.0
with:
python-version: 3.x
- uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4
- uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5
with:
go-version: "1.20"
go-version: "1.21"
- name: Get golangci
run: curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.54.2
- uses: pre-commit/[email protected]
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr-welcome.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: 'Comment on PR'
uses: actions/github-script@d7906e4ad0b1822421a7e6a35d5ca353c962f410 # v6
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@ on:
jobs:
build:
name: Push Release
runs-on: ubuntu-latest
runs-on: ARM64
permissions:
contents: write
packages: write
id-token: write # needed for signing the images with GitHub OIDC Token **not production ready**

# keda-tools is built from github.com/test-tools/tools/Dockerfile
container: ghcr.io/kedacore/keda-tools:1.20.8
container: ghcr.io/kedacore/keda-tools:1.21.5
steps:
- name: Check out code
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
with:
fetch-depth: 1

Expand All @@ -41,7 +41,7 @@ jobs:
key: ${{ runner.os }}-go-build-cache-${{ hashFiles('**/go.sum') }}

- name: Go modules sync
run: go mod tidy -compat=1.20
run: go mod tidy -compat=1.21

- name: Login to GitHub Container Registry
uses: docker/login-action@v3
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/static-analysis-codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ jobs:
codeQl:
name: Analyze CodeQL Go
runs-on: ubuntu-latest
container: ghcr.io/kedacore/keda-tools:1.20.8
container: ghcr.io/kedacore/keda-tools:1.21.5
if: (github.actor != 'dependabot[bot]')
steps:
- name: Checkout repository
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- name: Register workspace path
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/static-analysis-semgrep.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
container: returntocorp/semgrep
if: (github.actor != 'dependabot[bot]')
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- name: Register workspace path
if: ${{ github.event.number > 0 }}
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/template-main-e2e-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
name: Run e2e test
runs-on: ARM64
# keda-tools is built from github.com/test-tools/tools/Dockerfile
container: ghcr.io/kedacore/keda-tools:1.20.8
container: ghcr.io/kedacore/keda-tools:1.21.5
concurrency: e2e-tests
steps:
- name: Check out code
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
with:
fetch-depth: 1

Expand Down Expand Up @@ -47,7 +47,7 @@ jobs:
NODE_POOL_SIZE: 1

- name: Upload test logs
uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 # v3
uses: actions/upload-artifact@c7d193f32edcb7bfad88892161225aeda64e9392 # v4
if: ${{ always() }}
with:
name: e2e-test-logs
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/template-smoke-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ jobs:
runs-on: ${{ inputs.runs-on }}
steps:
- name: Setup Go
uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5
with:
go-version: "1.20"
go-version: "1.21"

- name: Install prerequisites
run: |
Expand All @@ -30,7 +30,7 @@ jobs:
DEBIAN_FRONTEND: noninteractive

- name: Check out code
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
with:
fetch-depth: 1

Expand All @@ -44,9 +44,9 @@ jobs:
run: make smoke-test

- name: Upload test logs
uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 # v3
uses: actions/upload-artifact@c7d193f32edcb7bfad88892161225aeda64e9392 # v4
if: ${{ always() }}
with:
name: smoke-test-logs ${{ inputs.kubernetesVersion }}
path: '${{ github.workspace }}/tests/**/*.log'
name: smoke-test-logs ${{ inputs.runs-on }}-${{ inputs.kubernetesVersion }}
path: "${{ github.workspace }}/tests/**/*.log"
if-no-files-found: ignore
2 changes: 1 addition & 1 deletion .github/workflows/template-trivy-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
name: Trivy - ${{ inputs.runs-on }} - ${{ inputs.scan-type }} ${{ inputs.image-ref }}
runs-on: ${{ inputs.runs-on }}
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4

- name: Run Trivy
uses: aquasecurity/[email protected]
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/v1-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
container: kedacore/build-tools:v1
steps:
- name: Check out code
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
with:
fetch-depth: 1

Expand Down
21 changes: 20 additions & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ linters:
- ineffassign
- staticcheck
- exportloopref
#- depguard #https://github.com/kedacore/keda/issues/4980
- depguard
- dogsled
- errcheck
#- funlen
Expand Down Expand Up @@ -136,6 +136,19 @@ issues:
- path: azure_pipelines_scaler.go
linters:
- gocritic
# Following 3 depguard exceptions are for disabling sync/atomic package where
# denying the rule doesnt help (bottom of this file) but this keeps the depguard
# linter enabled
# https://github.com/kedacore/keda/issues/4980
- path: pkg/scalers/external_mock_scaler.go
linters:
- depguard
- path: controllers/keda/scaledobject_controller_test.go
linters:
- depguard
- path: pkg/scalers/external_scaler_test.go
linters:
- depguard


linters-settings:
Expand All @@ -147,3 +160,9 @@ linters-settings:
- standard
- default
- prefix(github.com/kedacore/keda)
depguard: #https://github.com/kedacore/keda/issues/4980
rules:
main:
deny:
- pkg: sync/atomic
desc: "use type-safe atomics from go.uber.org/atomic"
Loading

0 comments on commit 12cc370

Please sign in to comment.