Skip to main content
Apr 10, 2025 2:18 PM UTC
Solved

Regrding Maven Build Issue In Cloud Pipeline

Dear All,

 

We are migrating AEM 6.5 to AEM cloud.

 

We saw below error log in the maven build

 

Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:1.4.1:enforce (enforce-maven) on project

 

We have updated the java 11 as shown below. Still we are getting build error. 

 

 

Can anyone please help here.

 

Thanks in Advance

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
muskaanchandwani
muskaanchandwaniAccepted solution
Adobe Employee
Apr 11, 2025 6:27 PM UTC

4 replies

Harwinder-singh
Community Advisor
Community Advisor
Apr 10, 2025 5:32 PM UTC

@sunitach2 Are you running this build locally or is this error coming out of a pipeline build ? 

Translate
muskaanchandwani
Adobe Employee
muskaanchandwaniAdobe EmployeeAccepted solution
Adobe Employee
Apr 11, 2025 6:27 PM UTC
SantoshSai
Community Advisor
Community Advisor
Apr 15, 2025 4:02 PM UTC

HI @sunitach2,

I think you forgot this,

To ensure Cloud Manager uses the correct Java version (Java 11) during the build process, you need to explicitly define it using the .cloudmanager/java-version file.

What to Do

Create a file named:

.cloudmanager/java-version

And add the following exact content inside it:

11

No spaces, no extra lines — just 11.

 

Hope that helps!

Regards,
Santosh

Translate
Santosh Sai
kautuk_sahni
Level 9
Jun 27, 2025 8:51 AM UTC

@sunitach2 Just checking in — were you able to resolve your issue?
We’d love to hear how things worked out. If the suggestions above helped, marking a response as correct can guide others with similar questions. And if you found another solution, feel free to share it — your insights could really benefit the community. Thanks again for being part of the conversation!

Translate
Kautuk Sahni