Skip to content

Commit 4c4df84

Browse files
authored
Merge branch 'main' into external-file-mgmt-integration
2 parents 13f6d1f + 02f4c36 commit 4c4df84

File tree

103 files changed

+3031
-1330
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

103 files changed

+3031
-1330
lines changed

.github/workflows/assertion.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,9 @@ on:
3939
ARTIFACTORY_URL:
4040
required: true
4141

42+
permissions:
43+
contents: read
44+
4245
jobs:
4346
build-assertion-document:
4447
name: Create Assertion Document

.github/workflows/ci.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -81,20 +81,20 @@ jobs:
8181
uses: golangci/golangci-lint-action@1e7e51e771db61008b38414a730f564565cf7c20 # v9.2.0
8282
with:
8383
version: v2.4.0
84+
skip-cache: true
8485

8586
vulnerability-scan:
8687
name: Vulnerability Scan
8788
uses: ./.github/workflows/vulncheck.yml
8889
permissions:
89-
security-events: write
90+
contents: read
91+
security-events: write # for reporting vulnerabilities via code-scanning API
9092
with:
9193
target-branch: ${{ github.event.pull_request.base.ref || github.ref_name }}
9294

9395
unit-test:
9496
name: Unit Tests
9597
runs-on: ubuntu-22.04
96-
permissions:
97-
contents: write
9898
steps:
9999
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
100100
- name: Configure Go Proxy
@@ -591,7 +591,7 @@ jobs:
591591
runs-on: ubuntu-22.04
592592
needs: build-unsigned-snapshot
593593
permissions:
594-
contents: write
594+
contents: write # Needed for pushing benchmark results to github branch
595595
steps:
596596
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
597597
- name: Configure Go Proxy
@@ -633,7 +633,7 @@ jobs:
633633
name: Load Tests
634634
if: ${{ !github.event.pull_request.head.repo.fork && !startsWith(github.head_ref, 'dependabot-') }}
635635
permissions:
636-
contents: write
636+
contents: write # Needed for pushing benchmark results to github branch
637637
runs-on: ubuntu-22.04
638638
needs: build-unsigned-snapshot
639639
steps:
@@ -657,7 +657,7 @@ jobs:
657657
path: build
658658

659659
- name: Set up Docker Build
660-
uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
660+
uses: docker/setup-buildx-action@8d2750c68a42422c14e847fe6c8ac0403b4cbd6f # v3.12.0
661661

662662
- name: Set env
663663
run: echo "GO_VERSION=$(cat go.mod | grep toolchain | sed 's/toolchain //; s/go//')" >> $GITHUB_ENV

.github/workflows/dependency-review.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,4 @@ jobs:
2727
- name: "Dependency Review"
2828
uses: actions/dependency-review-action@3c4e3dcb1aa7874d2c16be7d79418e9b7efd6261 # v4.8.2
2929
with:
30-
config-file: "nginxinc/k8s-common/dependency-review-config.yml@main"
30+
config-file: "nginx/k8s-common/dependency-review-config.yml@main"

.github/workflows/nightly-scans.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,24 @@ on:
44
- cron: '0 2 * * *' # Runs daily at 2:00 AM UTC
55
workflow_dispatch:
66

7+
permissions:
8+
contents: read
9+
710
jobs:
811
scan-main:
912
name: Vulnerability Scan - Main
1013
uses: ./.github/workflows/vulncheck.yml
14+
permissions:
15+
contents: read
16+
security-events: write # for reporting vulnerabilities via code-scanning API
1117
with:
1218
target-branch: 'main'
1319

1420
scan-v2:
1521
name: Vulnerability Scan - dev-v2
1622
uses: ./.github/workflows/vulncheck.yml
23+
permissions:
24+
contents: read
25+
security-events: write # for reporting vulnerabilities via code-scanning API
1726
with:
1827
target-branch: 'dev-v2'

.github/workflows/release-branch.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ jobs:
185185
runs-on: ubuntu-22.04
186186
needs: [vars,release-draft]
187187
permissions:
188-
contents: write
188+
contents: write # Needed to tag a release
189189
steps:
190190
- name: Checkout Repository
191191
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
@@ -206,8 +206,7 @@ jobs:
206206
runs-on: ubuntu-22.04-amd64
207207
needs: [vars,release-draft,tag-release]
208208
permissions:
209-
id-token: write
210-
contents: write # Needed to update a release
209+
id-token: write # Needed to get a token to upload packages to NGINX repo
211210
steps:
212211
- name: Checkout Repository
213212
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
@@ -314,7 +313,7 @@ jobs:
314313
runs-on: ubuntu-22.04
315314
needs: [vars,tag-release]
316315
permissions:
317-
pull-requests: write
316+
pull-requests: write # Needed to create pull request back into main branch
318317
steps:
319318
- name: Checkout Repository
320319
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1

.github/workflows/scorecards.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,6 @@ jobs:
5555

5656
# Upload the results to GitHub's code scanning dashboard.
5757
- name: "Upload to code-scanning"
58-
uses: github/codeql-action/upload-sarif@1b168cd39490f61582a9beae412bb7057a6b2c4e # v4.31.8
58+
uses: github/codeql-action/upload-sarif@cdefb33c0f6224e58673d9004f47f7cb3e328b89 # v4.31.10
5959
with:
6060
sarif_file: results.sarif

.github/workflows/upload-release-assets.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ defaults:
2525
shell: bash
2626

2727
permissions:
28-
contents: write
28+
contents: read
2929

3030
jobs:
3131
vars:
@@ -51,6 +51,8 @@ jobs:
5151
name: Upload assets
5252
runs-on: ubuntu-22.04
5353
needs: [vars]
54+
permissions:
55+
contents: write # Needed for uploading release assets to GitHub
5456
steps:
5557
- name: Checkout Repository
5658
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1

.github/workflows/vulncheck.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ on:
1414
required: false
1515
default: 'main'
1616

17+
permissions:
18+
contents: read
19+
1720
jobs:
1821
vulncheck:
1922
name: Vulnerability Check
@@ -25,7 +28,7 @@ jobs:
2528
uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5.0.1
2629
with:
2730
fetch-depth: 0
28-
ref: ${{ inputs.targetBranch || 'main' }}
31+
ref: ${{ inputs.target-branch || 'main' }}
2932

3033
- name: Check Go version
3134
id: get-go-version

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ whitesource/
77
.vscode/
88
.idea/
99
*.log
10+
!**/testdata/*.log
1011
*.test
1112
*.orig
1213
sdk/certs/**

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ $(RPM_PACKAGE):
110110
include Makefile.tools
111111
include Makefile.containers
112112
include Makefile.packaging
113+
include Makefile.weaver
113114

114115
.PHONY: help clean no-local-changes build lint format unit-test integration-test run dev run-mock-management-grpc-server generate generate-mocks local-apk-package local-deb-package local-rpm-package
115116
help: ## Show help message
@@ -282,7 +283,7 @@ stop-mock-otel-collector-without-nap: ## Stop running mock management plane OTel
282283
@echo "Stopping mock management plane OTel collector without NAP"
283284
AGENT_IMAGE_WITH_NGINX_PLUS=nginx_plus_$(IMAGE_TAG):latest AGENT_IMAGE_WITH_NGINX_OSS=nginx_oss_$(IMAGE_TAG):latest $(CONTAINER_COMPOSE) -f ./test/mock/collector/docker-compose.yaml down
284285

285-
generate: ## Generate golang code
286+
generate: nginx-metadata-gen nginxplus-metadata-gen ## Generate golang code
286287
@echo "🗄️ Generating proto files"
287288
@cd api/grpc && $(GORUN) $(BUF) generate
288289
@echo "🗃️ Generating go files"

0 commit comments

Comments
 (0)