Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
105 commits
Select commit Hold shift + click to select a range
ec00626
Bump certifi from 2022.9.14 to 2022.9.24 in /perf-tests (#3099)
dependabot[bot] Sep 27, 2022
bbe3ae9
Bump certifi from 2022.9.14 to 2022.9.24 in /tests (#3100)
dependabot[bot] Sep 27, 2022
296737d
Fix staticcheck linter issues (#3097)
jjngx Sep 27, 2022
5d9ccff
Add RBAC for coordination.k8s.io/leases (#3101)
coolbry95 Sep 27, 2022
fcbbca9
Eliminate dead code (#3104)
jjngx Sep 27, 2022
6b0a2c9
Add `ARCH` in Makefile, make Dockerfile more compatible with podman (…
lucacome Sep 28, 2022
88fb869
Fix helm chart issue when set controller.strategy (#3106)
wd Sep 28, 2022
3406737
Optimise path validation (#3094)
haywoodsh Sep 28, 2022
f07a0a8
Fix staticcheck linter issues in k8s, nginx packages (#3107)
jjngx Sep 29, 2022
b14dc84
Apdoslogconf will warning case format is not splunk (#2991)
pasmant Sep 29, 2022
59ed736
add canary header and update syslog yaml for AP tests (#3116)
vepatel Sep 30, 2022
3d696b7
Update packages for CVE-2022-40674 (#3115)
lucacome Sep 30, 2022
28c0449
Pass Git info to Docker (#3112)
lucacome Sep 30, 2022
c30721e
Bump github.com/aws/aws-sdk-go-v2/config from 1.17.7 to 1.17.8 (#3117)
dependabot[bot] Sep 30, 2022
ab8ac9c
Update helm rbac template for watch-ns (#3122)
vepatel Oct 3, 2022
de7bb29
Announce release in Community Slack (#3124)
lucacome Oct 3, 2022
becef0b
Upload Release artifacts to Azure (#3123)
lucacome Oct 4, 2022
a77aa1b
Don't use `latest` tag for AWS images (#3125)
lucacome Oct 4, 2022
2bf9de8
Release 2.4.0 (#3109)
shaun-nx Oct 4, 2022
6e792cb
docs: Release note fix (#3126)
ciarams87 Oct 4, 2022
a1ff305
Add JSON Schema for Helm Chart (#3113)
lucacome Oct 4, 2022
912dcd3
Bump google.golang.org/grpc from 1.49.0 to 1.50.0 (#3130)
dependabot[bot] Oct 6, 2022
32c51f4
Bump github.com/kr/pretty from 0.3.0 to 0.3.1 (#3137)
dependabot[bot] Oct 10, 2022
6e9b590
add caseSensitiveHttpHeaders to appolicy crd (#3133)
galitskiy Oct 10, 2022
8471da0
[StepSecurity] ci: Harden GitHub Actions (#3134)
step-security-bot Oct 11, 2022
7d20c17
Re-order and adjust custom resource headings for installation via man…
ADubhlaoich Oct 12, 2022
dfed79d
Add make target for running staticcheck locally (#3110)
jjngx Oct 13, 2022
333af16
Add OpenSSF Scorecard Github Action and Badge (#3132)
lucacome Oct 13, 2022
a2a5631
Bump k8s.io/client-go from 0.25.2 to 0.25.3 (#3147)
dependabot[bot] Oct 14, 2022
e4b27f9
Bump ossf/scorecard-action from 2.0.3 to 2.0.4 (#3146)
dependabot[bot] Oct 14, 2022
7585731
Bump k8s.io/code-generator from 0.25.2 to 0.25.3 (#3149)
dependabot[bot] Oct 14, 2022
f6a502a
Add controller.dnsPolicy to the helm chart (#3136)
wd Oct 14, 2022
148c542
Remove all IPV6 listeners in ingress resources with -disable-ipv6 com…
haywoodsh Oct 14, 2022
9098f86
Push NAP DoS image to AWS Marketplace (#3131)
lucacome Oct 15, 2022
c14d3fa
Restore pushing `edge` for Plus images (#3162)
lucacome Oct 18, 2022
409bea9
Fix typo in Action.Proxy.ResponseHeaders (#3157)
tomasohaodha Oct 18, 2022
4f03000
Update golang.org/x/text for CVE-2022-32149 (#3153)
lucacome Oct 18, 2022
bdf70a8
Add CODEOWNERS (#3151)
lucacome Oct 18, 2022
80f07f3
Bump more-itertools from 8.14.0 to 9.0.0 in /tests (#3168)
dependabot[bot] Oct 18, 2022
51fcbba
Bump google.golang.org/grpc from 1.50.0 to 1.50.1 (#3160)
dependabot[bot] Oct 18, 2022
a1fdee9
Bump grpcio from 1.49.1 to 1.50.0 in /tests (#3173)
dependabot[bot] Oct 18, 2022
451f9e4
Bump ossf/scorecard-action from 2.0.4 to 2.0.5 (#3172)
dependabot[bot] Oct 19, 2022
ec7af46
Run CI for docs changes (#3163)
lucacome Oct 19, 2022
6cf5fcf
Bump locust from 2.12.1 to 2.12.2 in /perf-tests (#3159)
dependabot[bot] Oct 19, 2022
522f309
Bump ossf/scorecard-action from 2.0.5 to 2.0.6 (#3179)
dependabot[bot] Oct 19, 2022
556018c
feat: October/22 f5-hugo theme bump (#3182)
ADubhlaoich Oct 19, 2022
16e2efd
Bump nginx from 1.23.1 to 1.23.2 in /build (#3188)
dependabot[bot] Oct 19, 2022
66490bf
chore: Update cert-manager to latest (#3181)
ciarams87 Oct 20, 2022
3afa671
Add annotations for deployment and daemonset (#3143)
jasonwilliams14 Oct 21, 2022
bc848ad
Add annotations to the service account in the Helm chart (#3065)
0m1xa Oct 21, 2022
9f39676
Bump github.com/aws/aws-sdk-go-v2/service/marketplacemetering from 1.…
dependabot[bot] Oct 24, 2022
f60aa40
Bump github.com/aws/aws-sdk-go-v2/config from 1.17.8 to 1.17.10 (#3200)
dependabot[bot] Oct 24, 2022
e1ec33c
Bump github.com/aws/aws-sdk-go-v2/service/marketplacemetering from 1.…
dependabot[bot] Oct 24, 2022
a4b299e
Bump github.com/stretchr/testify from 1.8.0 to 1.8.1 (#3197)
dependabot[bot] Oct 25, 2022
4155595
Update test action (#3189)
lucacome Oct 25, 2022
f7e563e
Bump pytest from 7.1.3 to 7.2.0 in /perf-tests (#3204)
dependabot[bot] Oct 25, 2022
165a447
Bump pytest-html from 3.1.1 to 3.2.0 in /tests (#3202)
dependabot[bot] Oct 25, 2022
a37bf93
Bump pytest from 7.1.3 to 7.2.0 in /tests (#3203)
dependabot[bot] Oct 25, 2022
fc6d996
Bump pytest-html from 3.1.1 to 3.2.0 in /perf-tests (#3205)
dependabot[bot] Oct 26, 2022
66cc802
Bump kindest/node from v1.25.2 to v1.25.3 in /tests/docker (#3207)
dependabot[bot] Oct 26, 2022
5a2b265
Bump kubernetes from 24.2.0 to 25.3.0 in /tests (#3209)
dependabot[bot] Oct 26, 2022
6f24a09
Bump kubernetes from 24.2.0 to 25.3.0 in /perf-tests (#3208)
dependabot[bot] Oct 26, 2022
dbbf3ad
Bump opentracing/nginx-opentracing from nginx-1.23.1 to nginx-1.23.2 …
dependabot[bot] Oct 26, 2022
bc8de24
fix: fix 2 broken links (#3211)
JTorreG Oct 27, 2022
c215873
Bump aquasecurity/trivy-action from 0.7.1 to 0.8.0 (#3216)
dependabot[bot] Nov 2, 2022
bdbd170
Bump anchore/sbom-action from 0.12.0 to 0.13.0 (#3215)
dependabot[bot] Nov 2, 2022
eab2bc2
Bump github.com/prometheus/client_golang from 1.13.0 to 1.13.1 (#3217)
dependabot[bot] Nov 2, 2022
175e508
Bump locust from 2.12.2 to 2.13.0 in /perf-tests (#3214)
dependabot[bot] Nov 2, 2022
45148e6
Use `nginxcontrib/nginx` as base image for UBI (#2845)
lucacome Nov 2, 2022
d3652bc
Bump nginxcontrib/nginx from 1.23.1-ubi to 1.23.2-ubi in /build (#3218)
dependabot[bot] Nov 3, 2022
6afddb5
Docs for 2.4.1 (#3184) (#3194)
ciarams87 Nov 3, 2022
d253d11
Bump grpcio-tools from 1.48.1 to 1.50.0 in /tests (#3169)
dependabot[bot] Nov 3, 2022
04def24
Add pre-commit configuration (#2154)
lucacome Nov 3, 2022
04271e7
Bump python from 3.10 to 3.11 in /tests/docker (#3206)
dependabot[bot] Nov 3, 2022
ff8081f
Support default client proxy headers to be overwritten in VirtualServ…
centromere Nov 4, 2022
568c707
Fix Makefile var overrides (#3224) (#3225)
hafe Nov 7, 2022
cc1a223
Run pre-commit to fix whitespaces/newlines (#3223)
lucacome Nov 7, 2022
aba7fba
Update helloworld grpc generated file (#3220)
lucacome Nov 7, 2022
27e9fea
Run pre-commit to fix whitespaces/newlines in tests (#3226)
lucacome Nov 7, 2022
2f4e977
Run pre-commit hooks to fix python test imports (#3221)
lucacome Nov 8, 2022
2fb2653
Bump anchore/sbom-action from 0.13.0 to 0.13.1 (#3229)
dependabot[bot] Nov 8, 2022
9edc4ba
Bump isort/isort-action from 1.0.0 to 1.1.0 (#3228)
dependabot[bot] Nov 8, 2022
bd1a735
Bump github.com/prometheus/client_golang from 1.13.1 to 1.14.0 (#3230)
dependabot[bot] Nov 8, 2022
26d6b5c
Unwrap error (#3234)
lucacome Nov 9, 2022
9f40d88
Remove unnecessary arg in generateTransportServerHealthCheckWithDefau…
lucacome Nov 9, 2022
c7e31dc
Always print build info, add flags used (#3231)
lucacome Nov 9, 2022
21a9530
Watch subset of namespaces for secrets (#3170)
hafe Nov 10, 2022
547e455
Update script logic for validating tag (#3237)
shaun-nx Nov 10, 2022
795aea1
Remove ineffective break (#3235)
lucacome Nov 10, 2022
15577fa
Add context to http calls (#3233)
lucacome Nov 11, 2022
659e99d
Fix git command to retrieve commit matching the tag (#3239)
lucacome Nov 11, 2022
4612d5e
Bump k8s.io/client-go from 0.25.3 to 0.25.4 (#3241)
dependabot[bot] Nov 11, 2022
bf18792
Bump k8s.io/code-generator from 0.25.3 to 0.25.4 (#3243)
dependabot[bot] Nov 11, 2022
fdcc0e8
Bump github.com/aws/aws-sdk-go-v2/service/marketplacemetering from 1.…
dependabot[bot] Nov 11, 2022
668122a
Bump github.com/aws/aws-sdk-go-v2/config from 1.17.10 to 1.18.0 (#3246)
dependabot[bot] Nov 14, 2022
25d74d7
Refactor watchers - Create separate type for namespaced informers (#3…
ciarams87 Nov 14, 2022
cabfc2c
Run golangci-lint in pre-commit only for changed files (#3247)
lucacome Nov 14, 2022
a0ea7e4
Add automated tests for -watch-secret-namespace (#3245)
vepatel Nov 15, 2022
99c4f57
Add linter for GitHub Actions (#3251)
lucacome Nov 15, 2022
8ea687c
Update packages for CVEs (#3258)
lucacome Nov 16, 2022
88572dd
Remove support for k8s < 1.21 (#3252)
lucacome Nov 16, 2022
1421bed
feat: F5-hugo Theme bump - November (#3263)
ADubhlaoich Nov 16, 2022
6c4e87b
Update minimum version in k8s version check (#3265)
ciarams87 Nov 17, 2022
096a3bb
fix: Pin ubi8 image to unblock nap ubi builds (#3267)
ciarams87 Nov 17, 2022
d40fb21
add horizontalpodautoscaler
coolbry95 Nov 14, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 3 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ grafana
tests/.pytest_cache
tests/__pycache__
hack
.git*
.git/modules
.git/rr-cache
.git/logs
*.md
*.crt
*.key
18 changes: 8 additions & 10 deletions .github/actions/smoke-tests/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,23 +33,23 @@ runs:
using: composite
steps:
- name: Fetch Cached Artifacts
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ${{ github.workspace }}/dist
key: nginx-ingress-${{ github.run_id }}-${{ github.run_number }}-single

- name: Ingress type
id: ingress-type
run: |
echo ::set-output name=name::nginx${{ contains(inputs.image, 'plus') && '-plus' || '' }}-ingress
echo ::set-output name=tag::${{ inputs.image }}${{ contains(inputs.image, 'nap') && '-dos' || '' }}-${{ github.sha }}
echo "name=nginx${{ contains(inputs.image, 'plus') && '-plus' || '' }}-ingress" >> $GITHUB_OUTPUT
echo "tag=${{ inputs.image }}${{ contains(inputs.image, 'nap') && '-dos' || '' }}-${{ github.sha }}" >> $GITHUB_OUTPUT
shell: bash

- name: Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v2

- name: Build ${{ inputs.image }} Container
uses: docker/build-push-action@v2
uses: docker/build-push-action@v3
with:
file: build/Dockerfile
context: '.'
Expand All @@ -68,7 +68,7 @@ runs:
${{ contains(inputs.image, 'plus') && format('"nginx-repo.key={0}"', inputs.nginx-key) || '' }}

- name: Build Test-Runner Container
uses: docker/build-push-action@v2
uses: docker/build-push-action@v3
with:
file: tests/docker/Dockerfile
context: '.'
Expand All @@ -81,15 +81,13 @@ runs:
- name: Deploy Kubernetes
id: k8s
run: |
# no support for dual stack in < 1.20, we need to use ipv4 only
printf '%s\n' "1.20.0" "${{ inputs.k8s-version }}" | sort --version-sort --check=quiet || echo "Using ipv4" && sed -i 's/dual/ipv4/g' ${{ github.workspace }}/tests/ci-files/ci-kind-config.yaml
kind create cluster --name ${{ github.run_id }} --image=kindest/node:v${{ inputs.k8s-version }} --config ${{ github.workspace }}/tests/ci-files/ci-kind-config.yaml --kubeconfig kube-${{ github.run_id }} --wait ${{ inputs.k8s-timeout }}
kind load docker-image docker.io/nginx/${{ steps.ingress-type.outputs.name }}:${{ steps.ingress-type.outputs.tag }} --name ${{ github.run_id }}
marker="${{ inputs.marker }}"
sanitized_marker="${marker// /_}"
name="${sanitized_marker:-${{ inputs.k8s-version }}}"
echo ::set-output name=cluster_ip::$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' ${{ github.run_id }}-control-plane)
echo ::set-output name=cluster::$(echo nginx-${{ inputs.image }}-$name)
echo "cluster_ip=$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' ${{ github.run_id }}-control-plane)" >> $GITHUB_OUTPUT
echo "cluster=$(echo nginx-${{ inputs.image }}-$name)" >> $GITHUB_OUTPUT
shell: bash

- name: Setup Kubeconfig
Expand Down
38 changes: 22 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,12 @@ on:
branches:
- main
- release-*
paths-ignore:
- 'docs/**'
- 'examples/**'
- '**.md'
tags:
- 'v[0-9]+.[0-9]+.[0-9]+'
pull_request:
branches:
- main
- release-*
paths-ignore:
- 'docs/**'
- 'examples/**'
- '**.md'
types:
- opened
- reopened
Expand Down Expand Up @@ -98,6 +90,8 @@ jobs:
GOPATH: ${{ needs.checks.outputs.go_path }}
AWS_PRODUCT_CODE: ${{ secrets.AWS_PRODUCT_CODE }}
AWS_PUB_KEY: ${{ secrets.AWS_PUB_KEY }}
AWS_NAP_DOS_PRODUCT_CODE: ${{ secrets.AWS_NAP_DOS_PRODUCT_CODE }}
AWS_NAP_DOS_PUB_KEY: ${{ secrets.AWS_NAP_DOS_PUB_KEY }}
- name: Store Artifacts in Cache
uses: actions/cache@v3
with:
Expand Down Expand Up @@ -226,8 +220,8 @@ jobs:
{\"image\": \"debian-plus-nap\", \"marker\": \"dos\"}], \
\"k8s\": [\"${{ needs.checks.outputs.k8s_latest }}\"]}"
else
echo "::set-output name=matrix::{\"k8s\": [\"1.19.16\", \"1.20.15\", \"1.21.14\", \"1.22.13\", \"1.23.10\", \"1.24.4\", \"${{ needs.checks.outputs.k8s_latest }}\"], \
\"images\": [{\"image\": \"debian\"}, {\"image\": \"debian-plus\"}]}"
echo "matrix={\"k8s\": [\"1.21.14\", \"1.22.15\", \"1.23.13\", \"1.24.7\", \"${{ needs.checks.outputs.k8s_latest }}\"], \
\"images\": [{\"image\": \"debian\"}, {\"image\": \"debian-plus\"}]}" >> $GITHUB_OUTPUT
fi

smoke-tests:
Expand Down Expand Up @@ -315,7 +309,7 @@ jobs:
if: startsWith(github.ref, 'refs/tags/')

- name: Download Syft
uses: anchore/sbom-action/download-syft@v0.12.0
uses: anchore/sbom-action/download-syft@v0.13.1

- name: Build binaries
uses: goreleaser/goreleaser-action@v3
Expand All @@ -327,6 +321,13 @@ jobs:
GOPATH: ${{ needs.checks.outputs.go_path }}
AWS_PRODUCT_CODE: ${{ secrets.AWS_PRODUCT_CODE }}
AWS_PUB_KEY: ${{ secrets.AWS_PUB_KEY }}
AWS_NAP_DOS_PRODUCT_CODE: ${{ secrets.AWS_NAP_DOS_PRODUCT_CODE }}
AWS_NAP_DOS_PUB_KEY: ${{ secrets.AWS_NAP_DOS_PUB_KEY }}
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_COMMUNITY }}
AZURE_STORAGE_ACCOUNT: ${{ secrets.AZURE_STORAGE_ACCOUNT }}
AZURE_STORAGE_KEY: ${{ secrets.AZURE_STORAGE_KEY }}
AZURE_BUCKET_NAME: ${{ secrets.AZURE_BUCKET_NAME }}

- name: Store Artifacts in Cache
uses: actions/cache@v3
with:
Expand All @@ -345,7 +346,7 @@ jobs:
platforms: ["linux/arm, linux/arm64, linux/amd64, linux/ppc64le, linux/s390x"]
include:
- image: ubi
platforms: "linux/arm64, linux/amd64, linux/s390x"
platforms: "linux/arm64, linux/amd64, linux/ppc64le, linux/s390x"
steps:
- name: Checkout Repository
uses: actions/checkout@v3
Expand Down Expand Up @@ -448,7 +449,7 @@ jobs:
BUILD_OS=${{ matrix.image }}
IC_VERSION=${{ steps.var.outputs.ic_version }}
- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@0.7.1
uses: aquasecurity/trivy-action@0.8.0
continue-on-error: true
with:
image-ref: nginx/nginx-ingress:${{ steps.meta.outputs.version }}
Expand Down Expand Up @@ -488,6 +489,9 @@ jobs:
- image: debian-plus-nap
platforms: "linux/amd64"
target: goreleaser
- image: debian-plus-nap
platforms: "linux/amd64"
target: aws

steps:
- name: Checkout Repository
Expand Down Expand Up @@ -529,8 +533,10 @@ jobs:
name=gcr.io/f5-gcs-7899-ptg-ingrss-ctlr/dev/nginx-ic${{ contains(matrix.image, 'nap') && '-dos' || '' }}/nginx-plus-ingress
name=gcr.io/f5-gcs-7899-ptg-ingrss-ctlr/release/nginx-ic${{ contains(matrix.image, 'nap') && '-dos' || '' }}/nginx-plus-ingress,enable=${{ startsWith(github.ref, 'refs/tags/') }}
name=gcr.io/f5-gcs-7899-ptg-ingrss-ctlr/staging/nginx-ic${{ contains(matrix.image, 'nap') && '-dos' || '' }}/nginx-plus-ingress,enable=${{ startsWith(github.ref, 'refs/heads/release') }}
name=709825985650.dkr.ecr.us-east-1.amazonaws.com/nginx/nginx-plus-ingress,enable=${{ startsWith(github.ref, 'refs/tags/') && contains(matrix.target, 'aws') }}
flavor: suffix=${{ contains(matrix.image, 'ubi') && '-ubi' || '' }}${{ contains(matrix.image, 'alpine') && '-alpine' || '' }}${{ contains(matrix.target, 'aws') && '-mktpl' || '' }},onlatest=true
name=709825985650.dkr.ecr.us-east-1.amazonaws.com/nginx/nginx-plus-ingress${{ contains(matrix.image, 'nap') && '-dos' || '' }},enable=${{ startsWith(github.ref, 'refs/tags/') && contains(matrix.target, 'aws') }}
flavor: |
suffix=${{ contains(matrix.image, 'ubi') && '-ubi' || '' }}${{ contains(matrix.image, 'alpine') && '-alpine' || '' }}${{ contains(matrix.target, 'aws') && '-mktpl' || '' }},onlatest=true
latest=${{ contains(matrix.target, 'aws') && 'false' || 'auto' }}
tags: |
type=edge
type=ref,event=branch,enable=${{ startsWith(github.ref, 'refs/heads/release') }}
Expand Down Expand Up @@ -593,7 +599,7 @@ jobs:
"nginx-repo.crt=${{ contains(matrix.image, 'nap') && secrets.NGINX_AP_CRT || secrets.NGINX_CRT }}"
"nginx-repo.key=${{ contains(matrix.image, 'nap') && secrets.NGINX_AP_KEY || secrets.NGINX_KEY }}"
- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@0.7.1
uses: aquasecurity/trivy-action@0.8.0
continue-on-error: true
with:
image-ref: docker.io/${{ matrix.image }}:${{ steps.meta.outputs.version }}
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,15 @@ concurrency:
group: ${{ github.ref_name }}-codeql
cancel-in-progress: true

permissions: # added using https://github.com/step-security/secure-workflows
contents: read

jobs:
analyze:
permissions:
actions: read # for github/codeql-action/init to get workflow details
contents: read # for actions/checkout to fetch code
security-events: write # for github/codeql-action/autobuild to send a status report
name: Analyze
runs-on: ubuntu-latest

Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/fossa.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ concurrency:
group: ${{ github.ref_name }}-fossa
cancel-in-progress: true

permissions: # added using https://github.com/step-security/secure-workflows
contents: read

jobs:

scan:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ name: "Pull Request Labeler"
on:
- pull_request_target

permissions: # added using https://github.com/step-security/secure-workflows
contents: read

jobs:
triage:
permissions:
Expand Down
15 changes: 9 additions & 6 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:

lint:
name: Lint
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- name: Checkout Repository
uses: actions/checkout@v3
Expand All @@ -39,9 +39,12 @@ jobs:
with:
only-new-issues: true

lint-python:
runs-on: ubuntu-20.04
actionlint:
name: Actionlint
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- uses: isort/[email protected]
- uses: psf/black@stable
- name: Checkout Repository
uses: actions/checkout@v3
- uses: reviewdog/action-actionlint@v1
with:
fail_on_error: true
1 change: 1 addition & 0 deletions .github/workflows/notifications.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
- "Fossa"
- "Lint"
- "Update Docker Images"
- "OpenSSF Scorecards"
types:
- completed

Expand Down
58 changes: 58 additions & 0 deletions .github/workflows/scorecards.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: OpenSSF Scorecards
on:
# Only the default branch is supported.
branch_protection_rule:
schedule:
- cron: '43 20 * * 0'
push:
branches: [ "main" ]

# Declare default permissions as read only.
permissions: read-all

jobs:
analysis:
name: Scorecards analysis
runs-on: ubuntu-latest
permissions:
# Needed to upload the results to code-scanning dashboard.
security-events: write
# Used to receive a badge.
id-token: write
# Needs for private repositories.
contents: read
actions: read

steps:
- name: "Checkout code"
uses: actions/checkout@a12a3943b4bdde767164f792f33f40b04645d846 # tag=v3.0.0
with:
persist-credentials: false

- name: "Run analysis"
uses: ossf/scorecard-action@99c53751e09b9529366343771cc321ec74e9bd3d # tag=v2.0.5
with:
results_file: results.sarif
results_format: sarif
repo_token: ${{ secrets.SCORECARD_READ_TOKEN }}

# Publish the results for public repositories to enable scorecard badges. For more details, see
# https://github.com/ossf/scorecard-action#publishing-results.
# For private repositories, `publish_results` will automatically be set to `false`, regardless
# of the value entered here.
publish_results: true

# Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
# format to the repository Actions tab.
- name: "Upload artifact"
uses: actions/upload-artifact@6673cd052c4cd6fcf4b4e6e60ea986c889389535 # tag=v3.0.0
with:
name: SARIF file
path: results.sarif
retention-days: 5

# Upload the results to GitHub's code scanning dashboard.
- name: "Upload to code-scanning"
uses: github/codeql-action/upload-sarif@5f532563584d71fdef14ee64d17bafb34f751ce5 # tag=v1.0.26
with:
sarif_file: results.sarif
6 changes: 6 additions & 0 deletions .github/workflows/stale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,14 @@ on:
schedule:
- cron: '30 1 * * *'

permissions: # added using https://github.com/step-security/secure-workflows
contents: read

jobs:
stale:
permissions:
issues: write # for actions/stale to close stale issues
pull-requests: write # for actions/stale to close stale PRs
runs-on: ubuntu-20.04
steps:
- uses: actions/stale@v6
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/update-docker-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ jobs:
IC_VERSION=v${{ needs.variables.outputs.kic-tag }}
if: ${{ matrix.needs-updating == 'true' }}
- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@0.7.1
uses: aquasecurity/trivy-action@0.8.0
continue-on-error: true
with:
image-ref: nginx/nginx-ingress:${{ steps.meta.outputs.version }}
Expand Down
32 changes: 30 additions & 2 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,26 @@ builds:
binary: nginx-ingress
tags:
- aws
- id: aws-nap-dos
goos:
- linux
goarch:
- amd64
flags:
- -trimpath
gcflags:
- all=-trimpath={{.Env.GOPATH}}
asmflags:
- all=-trimpath={{.Env.GOPATH}}
ldflags:
- -s -w -X main.version={{.Version}} -X main.productCode={{.Env.AWS_NAP_DOS_PRODUCT_CODE}} -X main.pubKeyString={{.Env.AWS_NAP_DOS_PUB_KEY}}
main: ./cmd/nginx-ingress/
binary: nginx-ingress
tags:
- aws

archives:
- id: kubernetes-ingress
format: binary
builds: [kubernetes-ingress]

changelog:
Expand All @@ -54,13 +70,25 @@ checksum:
name_template: 'checksums.txt'

sboms:
- artifacts: binary
- artifacts: archive
ids: [kubernetes-ingress]

release:
ids: [kubernetes-ingress]
extra_files:
- glob: ./dist/**.sbom

blobs:
- provider: azblob
bucket: '{{.Env.AZURE_BUCKET_NAME}}'
extra_files:
- glob: ./dist/**.sbom

milestones:
- close: true

announce:
slack:
enabled: true
channel: '#announcements'
message_template: 'NGINX Ingress Controller {{ .Tag }} is out! Check it out: {{ .ReleaseURL }}'
Loading