Bump golang.org/x/net from 0.30.0 to 0.33.0 #2133
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build, lint and test | |
on: | |
push: | |
branches: | |
- main | |
- renovate/** | |
pull_request: | |
jobs: | |
build: | |
name: Build integration for | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
goos: [ linux ] | |
goarch: [ amd64, arm64, arm ] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: 'go.mod' | |
- name: Build integration | |
env: | |
GOOS: ${{ matrix.goos }} | |
GOARCH: ${{ matrix.goarch }} | |
run: | | |
make compile | |
chart-lint: | |
name: Helm chart Lint | |
runs-on: ubuntu-latest | |
timeout-minutes: 10 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: helm/[email protected] | |
- name: Lint charts | |
run: ct --config .github/ct.yaml lint --debug | |
- name: Check for changed installable charts | |
id: list-changed | |
run: | | |
changed=$(ct --config .github/ct.yaml list-changed) | |
if [[ -n "$changed" ]]; then | |
echo "changed=true" >> $GITHUB_OUTPUT | |
fi | |
- name: Run helm unit tests | |
if: steps.list-changed.outputs.changed == 'true' | |
run: | | |
helm plugin install https://github.com/helm-unittest/helm-unittest --version=0.3.1 | |
for chart in $(ct --config .github/ct.yaml list-changed); do | |
if [ -d "$chart/tests/" ]; then | |
helm unittest $chart | |
else | |
echo "No unit tests found for $chart" | |
fi | |
done | |
docker-build: | |
name: Build docker image for integration tests | |
runs-on: ubuntu-latest | |
timeout-minutes: 10 | |
env: | |
DOCKER_BUILDKIT: '1' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Build docker image | |
uses: docker/build-push-action@v6 | |
with: | |
cache-from: type=gha | |
cache-to: type=gha,mode=max | |
context: . | |
outputs: type=docker,dest=nri-kube-events.tar | |
platforms: | | |
linux/amd64 | |
tags: e2e/nri-kube-events:test | |
- name: Upload Image | |
uses: actions/upload-artifact@v4 | |
with: | |
name: nri-kube-events | |
path: nri-kube-events.tar | |
retention-days: 1 | |
static-analysis: | |
name: Run all static analysis checks | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: 'go.mod' | |
- uses: newrelic/newrelic-infra-checkers@v1 | |
with: | |
golangci-lint-config: golangci-lint-limited | |
# - name: Semgrep | |
# uses: returntocorp/semgrep-action@v1 | |
# with: | |
# auditOn: push | |
- name: golangci-lint | |
uses: golangci/golangci-lint-action@v6 | |
continue-on-error: ${{ github.event_name != 'pull_request' }} | |
with: | |
only-new-issues: true | |
skip-pkg-cache: true | |
skip-build-cache: true | |
test: | |
name: Run unit tests | |
runs-on: ubuntu-latest | |
needs: [ build ] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: 'go.mod' | |
- name: Test | |
run: make test-unit | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@1e68e06f1dbfde0e4cefc87efeba9e4643565303 # v5.1.2 | |
with: | |
fail_ci_if_error: false | |
env: | |
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
test-integration: | |
name: Run integration tests | |
runs-on: ubuntu-latest | |
needs: [ docker-build ] | |
timeout-minutes: 10 | |
env: | |
DOCKER_BUILDKIT: '1' | |
strategy: | |
max-parallel: 5 | |
fail-fast: false | |
matrix: | |
k8sVersion: ["v1.31.0", "v1.30.0", "v1.29.5", "v1.28.3", "v1.27.5"] | |
cri: [ containerd ] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: 'go.mod' | |
- name: Setup Minikube | |
uses: manusa/[email protected] | |
with: | |
minikube version: v1.35.0 | |
kubernetes version: ${{ matrix.k8sVersion }} | |
driver: docker | |
github token: ${{ secrets.GITHUB_TOKEN }} | |
start args: "--container-runtime=${{ matrix.cri }}" | |
- name: Run integreation tests | |
run: make test-integration | |
- name: Download Image | |
uses: actions/download-artifact@v4 | |
with: | |
name: nri-kube-events | |
- name: Load image for chart testing | |
run: | | |
minikube image load nri-kube-events.tar | |
minikube image ls | |
kubectl create ns ct | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.9' | |
- uses: helm/[email protected] | |
- name: Test install charts | |
run: ct install --namespace ct --config .github/ct.yaml --debug | |
- name: Test upgrade charts | |
run: ct install --namespace ct --config .github/ct.yaml --debug --upgrade |