Copilot commented on code in PR #3092:
URL: https://github.com/apache/hugegraph/pull/3092#discussion_r3566000328


##########
hugegraph-server/Dockerfile-hstore:
##########
@@ -18,7 +18,7 @@
 
 # Dockerfile for HugeGraph Server (hstore backend)
 # 1st stage: build source code
-FROM maven:3.9.0-eclipse-temurin-11 AS build
+FROM --platform=$BUILDPLATFORM maven:3.9.0-eclipse-temurin-11 AS build

Review Comment:
   `$BUILDPLATFORM` is referenced in the `FROM --platform=...` line but is not 
declared as a build arg. On builders where this automatic arg is not implicitly 
available (or when BuildKit is disabled), it may expand to an empty string and 
produce an invalid `--platform=` value, breaking the Docker build. Declare `ARG 
BUILDPLATFORM` before the first `FROM` that uses it.



##########
hugegraph-server/Dockerfile:
##########
@@ -18,7 +18,7 @@
 
 # Dockerfile for HugeGraph Server
 # 1st stage: build source code
-FROM maven:3.9.0-eclipse-temurin-11 AS build
+FROM --platform=$BUILDPLATFORM maven:3.9.0-eclipse-temurin-11 AS build

Review Comment:
   `$BUILDPLATFORM` is referenced in the `FROM --platform=...` line but is not 
declared as a build arg. On builders where this automatic arg is not implicitly 
available (or when BuildKit is disabled), it may expand to an empty string and 
produce an invalid `--platform=` value, breaking the Docker build. Declare `ARG 
BUILDPLATFORM` before the first `FROM` that uses it.



##########
hugegraph-store/Dockerfile:
##########
@@ -18,7 +18,7 @@
 
 # Dockerfile for HugeGraph Store
 # 1st stage: build source code
-FROM maven:3.9.0-eclipse-temurin-11 AS build
+FROM --platform=$BUILDPLATFORM maven:3.9.0-eclipse-temurin-11 AS build

Review Comment:
   `$BUILDPLATFORM` is referenced in the `FROM --platform=...` line but is not 
declared as a build arg. On builders where this automatic arg is not implicitly 
available (or when BuildKit is disabled), it may expand to an empty string and 
produce an invalid `--platform=` value, breaking the Docker build. Declare `ARG 
BUILDPLATFORM` before the first `FROM` that uses it.



##########
hugegraph-pd/Dockerfile:
##########
@@ -18,7 +18,7 @@
 
 # Dockerfile for HugeGraph PD
 # 1st stage: build source code
-FROM maven:3.9.0-eclipse-temurin-11 AS build
+FROM --platform=$BUILDPLATFORM maven:3.9.0-eclipse-temurin-11 AS build

Review Comment:
   `$BUILDPLATFORM` is referenced in the `FROM --platform=...` line but is not 
declared as a build arg. On builders where this automatic arg is not implicitly 
available (or when BuildKit is disabled), it may expand to an empty string and 
produce an invalid `--platform=` value, breaking the Docker build. Declare `ARG 
BUILDPLATFORM` before the first `FROM` that uses it.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to