Skip to content

Commit 817fdcb

Browse files
authored
Merge branch 'master' into lint-action-fixes
2 parents 4c2c9f1 + e148afa commit 817fdcb

File tree

13 files changed

+215
-59
lines changed

13 files changed

+215
-59
lines changed

.github/workflows/docker-master.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
runs-on: ubuntu-latest
1616
steps:
1717
- name: Checkout code
18-
uses: actions/checkout@v5
18+
uses: actions/checkout@v6
1919

2020
- name: Login to Github Packages
2121
uses: docker/login-action@v3

.github/workflows/docker-release.yaml

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
push:
55
tags:
66
- '[0-9]+.[0-9]+.[0-9]+'
7+
- 'cloudflare-exporter-[0-9]+.[0-9]+.[0-9]+'
78

89
jobs:
910
build-and-push-docker-image:
@@ -17,7 +18,16 @@ jobs:
1718
runs-on: ubuntu-latest
1819
steps:
1920
- name: Checkout code
20-
uses: actions/checkout@v5
21+
uses: actions/checkout@v6
22+
23+
- name: Extract version from tag
24+
id: version
25+
run: |
26+
TAG="${{ github.ref_name }}"
27+
# Strip 'cloudflare-exporter-' prefix if present
28+
VERSION="${TAG#cloudflare-exporter-}"
29+
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
30+
echo "Extracted version: $VERSION"
2131
2232
- name: Login to Github Packages
2333
uses: docker/login-action@v3
@@ -39,7 +49,7 @@ jobs:
3949
- name: Build and push
4050
id: publish-image
4151
env:
42-
IMAGE_VERSION: ${{ github.ref_name }}
52+
IMAGE_VERSION: ${{ steps.version.outputs.version }}
4353
KO_DOCKER_REPO: "ghcr.io/${{ github.repository }}"
4454
run: |
4555
ko build . --sbom=none --image-refs ./image-digest --bare --platform linux/arm64,linux/amd64 -t ${IMAGE_VERSION} \
@@ -80,9 +90,20 @@ jobs:
8090
permissions:
8191
packages: read
8292
steps:
93+
# Extract version again since this job runs on a different runner
94+
# and doesn't have access to outputs from the previous job's steps
95+
- name: Extract version from tag
96+
id: version
97+
run: |
98+
TAG="${{ github.ref_name }}"
99+
# Strip 'cloudflare-exporter-' prefix if present
100+
VERSION="${TAG#cloudflare-exporter-}"
101+
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
102+
echo "Extracted version: $VERSION"
103+
83104
- name: Copy image to dockerhub
84105
env:
85-
IMAGE_VERSION: ${{ github.ref_name }}
106+
IMAGE_VERSION: ${{ steps.version.outputs.version }}
86107
GHCR_REPO: "ghcr.io/${{ github.repository }}"
87108
GHCR_USERNAME: ${{ github.actor }}
88109
GHCR_PASSWORD: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/go-build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
runs-on: ubuntu-latest
1010
steps:
1111
- name: Checkout the repository
12-
uses: actions/checkout@v5
12+
uses: actions/checkout@v6
1313
- name: Generate build files
1414
uses: thatisuday/go-cross-build@v1
1515
with:

.github/workflows/golangci-lint.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ jobs:
1010
name: GO lang CI linter
1111
runs-on: ubuntu-latest
1212
steps:
13-
- uses: actions/checkout@v5
13+
- uses: actions/checkout@v6
1414
- uses: actions/setup-go@v6
1515
with:
1616
go-version: "1.25"
1717
- name: golangci-lint
18-
uses: golangci/golangci-lint-action@v8 # https://github.com/marketplace/actions/run-golangci-lint
18+
uses: golangci/golangci-lint-action@v9 # https://github.com/marketplace/actions/run-golangci-lint
1919
with:
2020
version: latest

.github/workflows/lint-test.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- name: Checkout
10-
uses: actions/checkout@v5
10+
uses: actions/checkout@v6
1111
with:
1212
fetch-depth: 0
1313

@@ -35,7 +35,7 @@ jobs:
3535
run: ct lint --target-branch master
3636

3737
- name: Create kind cluster
38-
uses: helm/kind-action@v1.12.0
38+
uses: helm/kind-action@v1.13.0
3939
if: steps.list-changed.outputs.changed == 'true'
4040

4141
- name: Run chart-testing (install)

.github/workflows/release.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
runs-on: ubuntu-latest
1111
steps:
1212
- name: Checkout
13-
uses: actions/checkout@v5
13+
uses: actions/checkout@v6
1414
with:
1515
fetch-depth: 0
1616

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,9 @@ Note: `ZONE_<name>` configuration is not supported as flag.
111111
# HELP cloudflare_zone_requests_content_type Number of request for zone per content type
112112
# HELP cloudflare_zone_requests_country Number of request for zone per country
113113
# HELP cloudflare_zone_requests_origin_status_country_host Count of not cached requests for zone per origin HTTP status per country per host
114+
# HELP cloudflare_zone_requests_origin_status_country_host_p50_ms P50 latency of not cached requests for zone per origin HTTP status per country per host, in ms
115+
# HELP cloudflare_zone_requests_origin_status_country_host_p95_ms P95 latency of not cached requests for zone per origin HTTP status per country per host, in ms
116+
# HELP cloudflare_zone_requests_origin_status_country_host_p99_ms P99 latency of not cached requests for zone per origin HTTP status per country per host, in ms
114117
# HELP cloudflare_zone_requests_ssl_encrypted Number of encrypted requests for zone
115118
# HELP cloudflare_zone_requests_status Number of request for zone per HTTP status
116119
# HELP cloudflare_zone_requests_status_country_host Count of requests for zone per edge HTTP status per country per host

charts/cloudflare-exporter/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ The following table lists the configurable parameters of the Cloudflare-exporter
2828
| `fullnameOverride` | | `""` |
2929
| `podAnnotations` | | `{}` |
3030
| `podSecurityContext` | | `{}` |
31+
| `priorityClassName` | | `""` |
3132
| `securityContext` | | `{}` |
3233
| `service.type` | | `"ClusterIP"` |
3334
| `service.port` | | `8080` |

charts/cloudflare-exporter/templates/deployment.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ spec:
5050
- secretRef:
5151
name: {{ .Values.secretRef }}
5252
{{- end }}
53+
{{- with .Values.priorityClassName}}
54+
priorityClassName: {{ . }}
55+
{{- end}}
5356
{{- with .Values.nodeSelector }}
5457
nodeSelector:
5558
{{- toYaml . | nindent 8 }}

charts/cloudflare-exporter/values.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,9 @@ serviceMonitor:
6565
targetLabels: []
6666
metricRelabelings: []
6767

68+
# Set priority class name https://kubernetes.io/docs/concepts/scheduling-eviction/pod-priority-preemption/#priorityclass
69+
priorityClassName: ""
70+
6871
resources: {}
6972
# We usually recommend not to specify default resources and to leave this as a conscious
7073
# choice for the user. This also increases chances charts run on environments with little

0 commit comments

Comments
 (0)