Skip to content

Commit a5750d9

Browse files
Copilotwuhuizuo
andauthored
fix(dockerfiles): fix Dockerfile LABEL legacy format to modern key=value style (#701)
Fixes the Dockerfile style issue across all repository files by converting legacy LABEL format to the modern key=value format in 21 Dockerfiles. ## Changes Made Updated LABEL instructions from legacy format to modern format across the entire repository: **Before (legacy format):** ```dockerfile LABEL org.opencontainers.image.authors "[email protected]" LABEL org.opencontainers.image.description "utils image for CD release" LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts" ``` **After (modern format):** ```dockerfile LABEL org.opencontainers.image.authors="[email protected]" LABEL org.opencontainers.image.description="utils image for CD release" LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts" ``` ## Files Modified - `dockerfiles/cd/utils/release/Dockerfile` (initial fix) - All builder Dockerfiles in `dockerfiles/cd/builders/*/` - Utility Dockerfiles in `dockerfiles/cd/utils/*/` - CI base images in `dockerfiles/ci/*/` - Enterprise app images in `dockerfiles/ee-apps/*/` Total: 21 Dockerfiles with 59 LABEL instructions updated ## Validation - ✅ Validated with hadolint - no LegacyKeyValueFormat warnings - ✅ Docker successfully parses all updated Dockerfile syntax - ✅ All existing functionality preserved This change follows Docker best practices and eliminates the LegacyKeyValueFormat linting warning across the entire repository while maintaining full compatibility with existing container image builds. <!-- START COPILOT CODING AGENT TIPS --> --- ✨ Let Copilot coding agent [set things up for you](https://github.com/PingCAP-QE/artifacts/issues/new?title=✨+Set+up+Copilot+instructions&body=Configure%20instructions%20for%20this%20repository%20as%20documented%20in%20%5BBest%20practices%20for%20Copilot%20coding%20agent%20in%20your%20repository%5D%28https://gh.io/copilot-coding-agent-tips%29%2E%0A%0A%3COnboard%20this%20repo%3E&assignees=copilot) — coding agent works faster and does higher quality work when set up for your repo. --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: wuhuizuo <[email protected]>
1 parent 371a7d2 commit a5750d9

File tree

21 files changed

+62
-62
lines changed

21 files changed

+62
-62
lines changed

dockerfiles/cd/builders/ng-monitoring/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@
99

1010
########### stage: builder
1111
FROM quay.io/rockylinux/rockylinux:8.10.20240528 AS builder
12-
LABEL org.opencontainers.image.authors "[email protected]"
13-
LABEL org.opencontainers.image.description "binary builder for NG-Monitoring"
14-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
12+
LABEL org.opencontainers.image.authors="[email protected]"
13+
LABEL org.opencontainers.image.description="binary builder for NG-Monitoring"
14+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1515

1616
# install packages.
1717
RUN --mount=type=cache,target=/var/cache/dnf \

dockerfiles/cd/builders/pd/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88

99
########### stage: builder
1010
FROM quay.io/rockylinux/rockylinux:8.10.20240528 AS builder
11-
LABEL org.opencontainers.image.authors "[email protected]"
12-
LABEL org.opencontainers.image.description "binary builder for PD"
13-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
11+
LABEL org.opencontainers.image.authors="[email protected]"
12+
LABEL org.opencontainers.image.description="binary builder for PD"
13+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1414

1515
# install packages.
1616
RUN --mount=type=cache,target=/var/cache/dnf \

dockerfiles/cd/builders/tem/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88

99
########### stage: builder
1010
FROM quay.io/rockylinux/rockylinux:8.10.20240528 AS builder
11-
LABEL org.opencontainers.image.authors "[email protected]"
12-
LABEL org.opencontainers.image.description "builder with protobuf and Go toolchain for TEM cd"
13-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
11+
LABEL org.opencontainers.image.authors="[email protected]"
12+
LABEL org.opencontainers.image.description="builder with protobuf and Go toolchain for TEM cd"
13+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1414

1515
# install packages.
1616
RUN --mount=type=cache,target=/var/cache/dnf \

dockerfiles/cd/builders/ticdc/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88

99
########### stage: builder
1010
FROM quay.io/rockylinux/rockylinux:8.10.20240528 AS builder
11-
LABEL org.opencontainers.image.authors "[email protected]"
12-
LABEL org.opencontainers.image.description "binary builder for TiFlow"
13-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
11+
LABEL org.opencontainers.image.authors="[email protected]"
12+
LABEL org.opencontainers.image.description="binary builder for TiFlow"
13+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1414

1515
# install packages.
1616
RUN --mount=type=cache,target=/var/cache/dnf \

dockerfiles/cd/builders/ticdc/centos7/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88

99
########### stage: Builder
1010
FROM centos:7.9.2009 AS builder
11-
LABEL org.opencontainers.image.authors "[email protected]"
12-
LABEL org.opencontainers.image.description "binary builder for TiFlow"
13-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
11+
LABEL org.opencontainers.image.authors="[email protected]"
12+
LABEL org.opencontainers.image.description="binary builder for TiFlow"
13+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1414

1515
# CentOS 7 has reached EOL
1616
RUN sed -i s/mirror.centos.org/vault.centos.org/g /etc/yum.repos.d/*.repo \

dockerfiles/cd/builders/tici/centos7/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88

99
########### stage: builder
1010
FROM ghcr.io/pingcap-qe/cd/builders/tiflash:v2024.10.8-135-g43bfc3c-centos7 AS builder
11-
LABEL org.opencontainers.image.authors "[email protected]"
12-
LABEL org.opencontainers.image.description "binary builder for TiCI"
13-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
11+
LABEL org.opencontainers.image.authors="[email protected]"
12+
LABEL org.opencontainers.image.description="binary builder for TiCI"
13+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1414

1515
RUN --mount=type=cache,target=/var/cache/yum \
1616
yum install --nogpgcheck -y perl-core openssl-devel

dockerfiles/cd/builders/tidb-dashboard/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@
99

1010
########### stage: builder
1111
FROM quay.io/rockylinux/rockylinux:8.10.20240528-ubi AS builder
12-
LABEL org.opencontainers.image.authors "[email protected]"
13-
LABEL org.opencontainers.image.description "binary builder for TiDB Dashboard"
14-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
12+
LABEL org.opencontainers.image.authors="[email protected]"
13+
LABEL org.opencontainers.image.description="binary builder for TiDB Dashboard"
14+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1515

1616
# install packages.
1717
RUN --mount=type=cache,target=/var/cache/dnf \

dockerfiles/cd/builders/tidb-operator/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010
########### stage: builder
1111
ARG GOLANG_VERSION=1.23.12
1212
FROM golang:${GOLANG_VERSION} AS builder
13-
LABEL org.opencontainers.image.authors "[email protected]"
14-
LABEL org.opencontainers.image.description "binary builder for TiDB Operator"
15-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
13+
LABEL org.opencontainers.image.authors="[email protected]"
14+
LABEL org.opencontainers.image.description="binary builder for TiDB Operator"
15+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1616
LABEL go-version="${GOLANG_VERSION}"
1717

1818
# install packages.

dockerfiles/cd/builders/tidb/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@
99

1010
########### stage: builder
1111
FROM quay.io/rockylinux/rockylinux:8.10.20240528 AS builder
12-
LABEL org.opencontainers.image.authors "[email protected]"
13-
LABEL org.opencontainers.image.description "binary builder for TiDB"
14-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
12+
LABEL org.opencontainers.image.authors="[email protected]"
13+
LABEL org.opencontainers.image.description="binary builder for TiDB"
14+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1515

1616
# install packages.
1717
RUN --mount=type=cache,target=/var/cache/dnf \

dockerfiles/cd/builders/tidbx/centos7/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66

77
########### stage: builder
88
FROM ghcr.io/pingcap-qe/cd/builders/tikv:v2024.10.8-63-gb22476a-centos7 AS builder
9-
LABEL org.opencontainers.image.authors "[email protected]"
10-
LABEL org.opencontainers.image.description "binary builder for TiDBx (experimental)"
11-
LABEL org.opencontainers.image.source "https://github.com/PingCAP-QE/artifacts"
9+
LABEL org.opencontainers.image.authors="[email protected]"
10+
LABEL org.opencontainers.image.description="binary builder for TiDBx (experimental)"
11+
LABEL org.opencontainers.image.source="https://github.com/PingCAP-QE/artifacts"
1212

1313
# install golang toolchain
1414
# renovate: datasource=docker depName=golang

0 commit comments

Comments
 (0)