Search code examples
antsap-commerce-cloud

BUILD FAILED hybris ant clean all


I have error build failed at the ant clean all on me local. the JAVA_HOME is C:\Progra~1\Java\jdk1.8.0_151 and hybris version is commerce-6.3.0.8

BUILD FAILED
C:\hybris\commerce-6.3.0.8\hybris\bin\platform\build.xml:20: The following error occurred while executing this line:
C:\hybris\commerce-6.3.0.8\hybris\bin\platform\resources\ant\compiling.xml:90: The following error occurred while executing this line:
C:\hybris\commerce-6.3.0.8\hybris\bin\platform\resources\ant\compiling.xml:148: The following error occurred while executing this line:
C:\hybris\commerce-6.3.0.8\hybris\bin\platform\resources\ant\util.xml:20: The following error occurred while executing this line:
C:\hybris\commerce-6.3.0.8\hybris\bin\platform\resources\ant\compiling.xml:155: The following error occurred while executing this line:
C:\hybris\commerce-6.3.0.8\hybris\bin\platform\resources\ant\compiling.xml:297: The following error occurred while executing this line:
C:\hybris\commerce-6.3.0.8\hybris\bin\platform\resources\ant\util.xml:144: The following error occurred while executing this line:
C:\hybris\commerce-6.3.0.8\hybris\bin\ext-content\personalizationsmartedit\buildcallbacks.xml:65: The following error occurred while executing this line:
C:\hybris\commerce-6.3.0.8\hybris\bin\ext-content\npmancillary\buildcallbacks.xml:276: exec returned: 3

   <!-- \platform\build.xml:20: The following error occurred while executing this line:-->
    <target name="build" depends="updateMavenDependencies" description="Builds all extensions">
        <callback extname="" target="before_build"/>
        <build/>
        <callback extname="" target="after_build"/>
    </target>

    <!-- ant\compiling.xml:90: The following error occurred while executing this line:-->
     <extensions_build/>

     <!--ant\compiling.xml:148: The following error occurred while executing this line:-->
    <else>
        <external_extension_build extname="@{extname}"/>
    </else>

<!-- \ant\util.xml:20: The following error occurred while executing this line:-->
<for list="${extension.names}" param="@{param}" delimiter=";">

<!--\ant\compiling.xml:155: The following error occurred while executing this line:-->
      <then>
          <extension_build extname="@{extname}" />
      </then>

<!-- \bin\ext-content\npmancillary\buildcallbacks.xml:276: exec returned: 3 -->
    <exec dir="@{path}" executable="${loc.NPM_BINARIES_HOME}${file.separator}.bin${file.separator}grunt.cmd" failonerror="${failonerrorValue}">
	<env key="Path" value="${env.Path}${path.separator}${loc.EXTRA_PATH}"/>
	<env key="NPM_HOME" value="${loc.NPM_HOME}"/>
	<env key="NPM_BINARIES_HOME" value="${loc.NPM_BINARIES_HOME}"/>
	<env key="NODE_HOME" value="${loc.NODE_HOME}"/>	
	<arg value="@{phase}"/>
	</exec>

<!-- bin\ext-content\personalizationsmartedit\buildcallbacks.xml:65: The following error occurred while executing this line:
<then>
	<linkToSELibraries path="${ext.personalizationsmartedit.path}"/>
	<gruntBuild path="${ext.personalizationsmartedit.path}" phase="packageSkipTests"/>
</then>


Solution

  • It is important to check your file permissions / owner. If you installed the application as root (not recommended), then the issue could be with the permissions set. Try to recursively set the owner of the files / folders to be the application owner (Assuming you set one up). In my instance I used "hybris" as the user / owner.

    chown -R hybris:users /opt/hybris