Skip to content

Commit 5ef73f1

Browse files
Merge branch 'origin-main' into hwa/fix_deep_copy_with_template
2 parents 0da5231 + 8d7515a commit 5ef73f1

281 files changed

Lines changed: 27602 additions & 17885 deletions

File tree

Some content is hidden

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

.coderabbit.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json
2+
# docs: https://docs.coderabbit.ai/reference/configuration
3+
reviews:
4+
poem: false
5+
high_level_summary: false
6+
estimated_code_review_effort: false
7+
suggested_labels: false
8+
suggested_reviewers: false
9+
review_status: false
10+
in_progress_fortune: false

.dockerignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
1+
data/
12
.build/
23
.tarballs/
34

45
!.build/linux-amd64/
5-
!.build/linux-armv7/
66
!.build/linux-arm64/
7+
!.build/linux-armv7/
78
!.build/linux-ppc64le/
9+
!.build/linux-riscv64/
810
!.build/linux-s390x/

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,3 +72,50 @@ body:
7272
label: Logs
7373
description: Insert Prometheus and Alertmanager logs relevant to the issue here.
7474
render: text
75+
- type: markdown
76+
attributes:
77+
value: |
78+
## Performance issues
79+
80+
The fields below are only relevant if you are reporting a performance issue (e.g. high CPU or memory usage). You can skip them otherwise.
81+
82+
You can upload the captured profiles to https://pprof.me/ and share the link to the profile diff between the previous and current versions.
83+
- type: textarea
84+
attributes:
85+
label: CPU profiles
86+
description: |
87+
Please attach CPU profiles from both the previous version (where performance was acceptable) and the current version (where you observe the regression). This helps us compare and identify the cause.
88+
89+
See the upstream Go documentation on diagnostics for how to capture profiles: https://go.dev/doc/diagnostics. You can capture a CPU profile with:
90+
91+
`go tool pprof http://<alertmanager-host>:9093/debug/pprof/profile?seconds=30`
92+
- type: textarea
93+
attributes:
94+
label: Memory profiles
95+
description: |
96+
Please attach memory (heap) profiles from both the previous version (where performance was acceptable) and the current version (where you observe the regression).
97+
98+
See the upstream Go documentation on diagnostics: https://go.dev/doc/diagnostics. You can capture a heap profile with:
99+
100+
`go tool pprof http://<alertmanager-host>:9093/debug/pprof/heap`
101+
- type: input
102+
attributes:
103+
label: Number of alerts
104+
description: Approximate number of alerts Alertmanager is handling when the issue occurs.
105+
- type: input
106+
attributes:
107+
label: Number of silences
108+
description: Approximate number of silences configured when the issue occurs.
109+
- type: markdown
110+
attributes:
111+
value: |
112+
## Using prometheus-operator?
113+
114+
If you deploy Alertmanager via [prometheus-operator](https://github.com/prometheus-operator/prometheus-operator), please confirm the checklist below before opening the issue.
115+
- type: checkboxes
116+
attributes:
117+
label: prometheus-operator checklist
118+
description: Only applicable if you use prometheus-operator to manage Alertmanager.
119+
options:
120+
- label: I have confirmed this issue is not caused by a missing feature in prometheus-operator.
121+
- label: I have reproduced this issue when running Alertmanager directly (without prometheus-operator).

.github/dependabot.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
###
2+
# Avoid syncing from prometheus/prometheus: no_prometheus_repo_sync
3+
###
14
version: 2
25
updates:
36
- package-ecosystem: "gomod"
@@ -13,6 +16,9 @@ updates:
1316
go.opentelemetry.io:
1417
patterns:
1518
- "go.opentelemetry.io/*"
19+
golang.org-x:
20+
patterns:
21+
- "golang.org/x/*"
1622
- package-ecosystem: "docker"
1723
directory: "/"
1824
schedule:
@@ -21,6 +27,20 @@ updates:
2127
directory: "/"
2228
schedule:
2329
interval: "monthly"
30+
groups:
31+
promci:
32+
patterns:
33+
- "prometheus/promci*"
34+
codeql:
35+
patterns:
36+
- "github/codeql-action*"
37+
# Exclude configs synced from upstream prometheus/prometheus.
38+
exclude-paths:
39+
- .github/workflows/container_description.yml
40+
- .github/workflows/golangci-lint.yml
41+
- .github/workflows/govulncheck.yml
42+
- .github/workflows/scorecards.yml
43+
- .github/workflows/stale.yml
2444
- package-ecosystem: "npm"
2545
directory: "/ui/mantine-ui"
2646
open-pull-requests-limit: 20
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
###
3+
# This action is synced from https://github.com/prometheus/prometheus
4+
###
5+
name: Approve pending workflows
6+
7+
on:
8+
issue_comment:
9+
types: [created]
10+
11+
permissions: read-all
12+
13+
jobs:
14+
approve:
15+
if: >-
16+
github.event.issue.pull_request &&
17+
github.event.comment.body == '/workflow-approve' &&
18+
(github.repository_owner == 'prometheus' || github.repository_owner == 'prometheus-community')
19+
runs-on: ubuntu-latest
20+
permissions:
21+
actions: write
22+
contents: read
23+
pull-requests: write
24+
steps:
25+
- uses: prometheus/promci/approve_workflows@370e8c15dcec50043cbe66f2f34633d9efc0a190 # v0.9.0
26+
with:
27+
github_token: ${{ github.token }}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
name: Build release branch
3+
on: # yamllint disable-line rule:truthy
4+
push:
5+
branches:
6+
- release-*
7+
workflow_dispatch:
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
ci:
13+
name: Run ci
14+
uses: ./.github/workflows/ci.yml
15+
16+
build:
17+
name: Build Alertmanager for all architectures
18+
runs-on: ubuntu-latest
19+
strategy:
20+
matrix:
21+
thread: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
22+
needs: ci
23+
steps:
24+
- uses: prometheus/promci/build@13941414d409d227afd67544e5d306827db5a1a2 # v0.8.5
25+
with:
26+
parallelism: 12
27+
thread: ${{ matrix.thread }}

.github/workflows/ci.yml

Lines changed: 37 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,24 +8,48 @@ jobs:
88
name: Test alertmanager frontend
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
11+
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
12+
with:
13+
persist-credentials: false
14+
- uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
15+
with:
16+
node-version-file: './.nvmrc'
17+
cache: 'npm'
18+
cache-dependency-path: |
19+
.nvmrc
20+
**/package-lock.json
1221
- run: make clean
1322
- run: make all
1423
working-directory: ./ui/app
1524
- run: make assets
1625
- run: make apiv2
1726
- run: git diff --exit-code
27+
- run: make assets-tarball
28+
- uses: prometheus/promci-artifacts/save@f9a587dbc0b2c78a0c54f8ad1cde71ea29a4b76f # v0.1.0
29+
with:
30+
directory: .tarballs
31+
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4.6.2
32+
with:
33+
name: ui-dist
34+
path: ui/app/dist
35+
include-hidden-files: true
1836

1937
build:
2038
name: Build Alertmanager for common architectures
39+
needs: [test_frontend]
2140
runs-on: ubuntu-latest
2241
strategy:
2342
matrix:
2443
thread: [0, 1, 2]
2544
steps:
26-
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4.0.0
27-
- uses: prometheus/promci@fc721ff8497a70a93a881cd552b71af7fb3a9d53 # v0.5.4
28-
- uses: ./.github/promci/actions/build
45+
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v4.0.0
46+
with:
47+
persist-credentials: false
48+
- uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
49+
with:
50+
name: ui-dist
51+
path: ui/app/dist
52+
- uses: prometheus/promci/build@13941414d409d227afd67544e5d306827db5a1a2 # v0.8.5
2953
with:
3054
promu_opts: "-p linux/amd64 -p windows/amd64 -p linux/arm64 -p darwin/amd64 -p darwin/arm64 -p linux/386"
3155
parallelism: 3
@@ -34,6 +58,7 @@ jobs:
3458
test:
3559
name: Test
3660
runs-on: ubuntu-latest
61+
needs: [test_frontend]
3762
# Whenever the Go version is updated here, .promu.yml
3863
# should also be updated.
3964
container:
@@ -51,8 +76,13 @@ jobs:
5176
EMAIL_NO_AUTH_CONFIG: testdata/noauth.yml
5277
EMAIL_AUTH_CONFIG: testdata/auth.yml
5378
steps:
54-
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
55-
- uses: prometheus/promci@fc721ff8497a70a93a881cd552b71af7fb3a9d53 # v0.5.4
56-
- uses: ./.github/promci/actions/setup_environment
79+
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
80+
with:
81+
persist-credentials: false
82+
- uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
83+
with:
84+
name: ui-dist
85+
path: ui/app/dist
86+
- uses: prometheus/promci-setup@3e5cd31b34b8ae19efa8f071c5e3cdb44884a7f8 # v0.2.1
5787
- run: make
5888
- run: git diff --exit-code

.github/workflows/container_description.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
---
2+
###
3+
# This action is synced from https://github.com/prometheus/prometheus
4+
###
25
name: Push README to Docker Hub
36
on:
47
push:
@@ -18,7 +21,7 @@ jobs:
1821
if: github.repository_owner == 'prometheus' || github.repository_owner == 'prometheus-community' # Don't run this workflow on forks.
1922
steps:
2023
- name: git checkout
21-
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
24+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
2225
with:
2326
persist-credentials: false
2427
- name: Set docker hub repo name
@@ -42,7 +45,7 @@ jobs:
4245
if: github.repository_owner == 'prometheus' || github.repository_owner == 'prometheus-community' # Don't run this workflow on forks.
4346
steps:
4447
- name: git checkout
45-
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
48+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
4649
with:
4750
persist-credentials: false
4851
- name: Set quay.io org name

.github/workflows/govulncheck.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
---
2+
###
3+
# This action is synced from https://github.com/prometheus/prometheus
4+
###
5+
name: govulncheck
6+
on:
7+
pull_request:
8+
paths:
9+
- VERSION
10+
- .github/workflows/govulncheck.yml
11+
push:
12+
branches:
13+
- main
14+
- master
15+
schedule:
16+
- cron: '33 2 * * *'
17+
18+
permissions:
19+
contents: read
20+
21+
jobs:
22+
govulncheck:
23+
runs-on: ubuntu-latest
24+
name: Run govulncheck
25+
steps:
26+
- name: Install snmp_exporter/generator dependencies
27+
id: snmp-deps
28+
run: sudo apt-get update && sudo apt-get -y install libsnmp-dev
29+
if: github.repository == 'prometheus/snmp_exporter'
30+
- id: govulncheck
31+
uses: golang/govulncheck-action@3fa7bd9cee2cfdf3499a8803b226e43de7b7cdb4 # master
32+
env:
33+
GOOS: ${{ contains(github.repository, 'windows_exporter') && 'windows' || '' }}

.github/workflows/mixin.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,20 @@ on:
44
paths:
55
- "doc/alertmanager-mixin/**"
66

7+
permissions:
8+
contents: read
9+
710
jobs:
811
mixin:
912
name: mixin-lint
1013
runs-on: ubuntu-latest
1114
steps:
1215
- name: Checkout repository
13-
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
16+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
17+
with:
18+
persist-credentials: false
1419
- name: install Go
15-
uses: actions/setup-go@4b73464bb391d4059bd26b0524d20df3927bd417 # v6.3.0
20+
uses: actions/setup-go@924ae3a1cded613372ab5595356fb5720e22ba16 # v6.5.0
1621
with:
1722
go-version: 1.26.x
1823
# pin the mixtool version until https://github.com/monitoring-mixins/mixtool/issues/135 is merged.

0 commit comments

Comments
 (0)