10-27-2019 02:02 PM
Hi all,
I created an intelliJ alfresco sdk 4.0 enterprise project on local machine(windows 64) wilth below configuration:
With below configuration in ~proj/pom.xml and using the alfresco 6.1 license .
<!-- Properties used in dependency declarations, you don't need to change these -->
<alfresco.groupId>org.alfresco</alfresco.groupId>
<alfresco.bomDependencyArtifactId>acs-packaging</alfresco.bomDependencyArtifactId>
<alfresco.platform.version>6.1.1.1</alfresco.platform.version>
<alfresco.share.version>6.1.1.1</alfresco.share.version>
<!-- Docker images -->
<docker.acs.image>alfresco/alfresco-content-repository</docker.acs.image>
<docker.share.image>alfresco/alfresco-share</docker.share.image>
But , when i started the project with command -
C:\github\acs> run.bat build_start
Get the below error:
-------------------------------------------
09260000 An IO error was encountered during deployment of the AMP into the WAR
Service 'acs-acs' failed to build: The command '/bin/sh -c java -jar $TOMCAT_DIR/alfresco-mmt/alfresco-mmt*.jar install $TOMCAT_DIR/amps $TOMCAT_DIR/webapps/alfresco -directory -nobackup -force' returned a non-zero code: 1
Attaching to
-----------------------------------------------
I checked that the application starts when we use:
<alfresco.platform.version>6.1.0.6</alfresco.platform.version>
<alfresco.share.version>6.2.0</alfresco.share.version>
Looks like since <alfresco.platform.version>6.1.1</alfresco.platform.version> it has started failing...
It failed for 6.1.1.
Can anyone suggest if he faced this issue and any possible fix.
12-11-2019 09:58 AM
The issue lies with the introduction of a custom user in the base image. This user is the default context for the RUN statement which installs AMP dependencies, but does not have the necessary file permissions to do so.
In a recent customer training I encountered this issue and changed the default Dockerfile. The following shows the critical section.
...
COPY Dockerfile extensions/*.amp $TOMCAT_DIR/amps/ USER root RUN java -jar $TOMCAT_DIR/alfresco-mmt/alfresco-mmt*.jar install \ $TOMCAT_DIR/amps $TOMCAT_DIR/webapps/alfresco -directory -nobackup -force USER alfresco
...
12-11-2019 11:48 AM
Yeah, seemed like permission issue. I was playing around this yesterday and changing the user to 'root' for run command allowed installing the amp file.
Alfresco team needs to fix this issue so we don't have to manipulate the DockerFile to manage any permissions.
[UPDATE]: It has been handled now. See here: https://github.com/Alfresco/acs-community-packaging/blob/develop/docker-alfresco/Dockerfile
10-28-2019 08:18 AM
Check your docker file in platform docker project. Add verbose flag to see full error log which may tell the cause of failure. I don't its related to alfresco version but not exactly sure, I am using "6.1.0.5" which was earlier stable version and i see no issues.
RUN java -jar $TOMCAT_DIR/alfresco-mmt/alfresco-mmt*.jar install \ $TOMCAT_DIR/amps $TOMCAT_DIR/webapps/alfresco -directory -nobackup -force -verbose
COPY Dockerfile extensions/*.amp $TOMCAT_DIR/amps/ RUN java -jar $TOMCAT_DIR/alfresco-mmt/alfresco-mmt*.jar install \ $TOMCAT_DIR/amps $TOMCAT_DIR/webapps/alfresco -directory -nobackup -force -verbose
Additionally make sure you have updated all the properties required for enterprise after getting SDK4 sample.You might have already made these changes but sharing again.
Here is a sample:
<!-- ACS and Share Enterprise version configuration ########################## [Start] --> <!-- Use 'acs-packaging' for enterprise edition else 'acs-community-packaging' is used for community --> <alfresco.bomDependencyArtifactId>acs-packaging</alfresco.bomDependencyArtifactId> <alfresco.platform.version>6.1.0.5</alfresco.platform.version> <alfresco.share.version>6.1.0</alfresco.share.version> <!-- Docker image for ACS, Visit for more details: https://hub.docker.com/r/alfresco/alfresco-content-repository/tags --> <docker.acs.image>alfresco/alfresco-content-repository</docker.acs.image> <!-- Docker image for Share, Visit for more details: https://hub.docker.com/r/alfresco/alfresco-share/tags --> <docker.share.image>alfresco/alfresco-share</docker.share.image> <!-- ACS and Share Enterprise version configuration ########################## [End] -->
See more details here: https://github.com/Alfresco/alfresco-sdk/blob/master/docs/advanced-topics/working-with-enterprise/RE...
12-05-2019 01:47 PM
I can verify the issue originally posted: I created a new SDK 4.0 project using Alfresco enterprise 6.1.0 (with all the correct enterprise settings in the parent pom). "./run.sh build_start" builds and starts it successfully. If the Alfresco version is changed to 6.1.1 or 6.2.0, then it fails to start when deploying the amps to the ACS docker container.
I also verified that 6.1.0.5 works fine as abhinavmishra14 notes. This unfortunately does not help solve the actual problem.
12-06-2019 01:00 PM
I just tried to verify this issue reported above, i am able to replicate this issue when i change the enterprise version from 6.1.0.5 to 6.2.0. People are reporting same issue with other lower versions. But works fine for 6.1.0.5.
Here is the enterprise config which i made in parent pom as per the documentation:
<!-- ACS and Share Enterprise version configuration ########################## [Start] --> <alfresco.bomDependencyArtifactId>acs-packaging</alfresco.bomDependencyArtifactId> <alfresco.platform.version>6.2.0</alfresco.platform.version> <alfresco.share.version>6.2.0</alfresco.share.version> <docker.acs.image>alfresco/alfresco-content-repository</docker.acs.image> <docker.share.image>alfresco/alfresco-share</docker.share.image> <!-- ACS and Share Enterprise version configuration ########################## [End] -->
I got the same error as other folks have reported. See the log below :
An IO error was encountered during deployment of the AMP into the WAR
Step 1/10 : FROM alfresco/alfresco-content-repository:6.2.0 ---> 7e3a8e4db2cd Step 2/10 : ARG TOMCAT_DIR=/usr/local/tomcat ---> Using cache ---> bbca02a86fa4 Step 3/10 : COPY Dockerfile extensions/*.jar $TOMCAT_DIR/webapps/alfresco/WEB-INF/lib/ ---> b5a18565ad3e Step 4/10 : COPY Dockerfile extensions/*.amp $TOMCAT_DIR/amps/ ---> e3521651175f Step 5/10 : RUN java -jar $TOMCAT_DIR/alfresco-mmt/alfresco-mmt*.jar install $TOMCAT_DIR/amps $TOMCAT_DIR/webapps/alfresco -directory -nobackup -force -verbose ---> Running in 2f5cdafa43be Installing AMP '/usr/local/tomcat/amps/alfresco-device-sync-repo-3.2.0.amp' into WAR '/usr/local/tomcat/webapps/alfresco' INFO: Checking the war version using /WEB-INF/classes/alfresco/version.properties WARNING: The installation of this module is being forced. All files will be removed and replaced regardless of existing versions present. WARNING: This version of this module is already installed in the WAR..upgrading. Clearing out files relating to version '3.2.0' of module 'org_alfresco_device_sync_repo' - Removing file '/WEB-INF/lib/services-common-1.6.jar' from war - Removing file '/WEB-INF/lib/postgresql-42.2.6.jar' from war - Removing file '/WEB-INF/lib/alfresco-device-sync-repo-3.2.0.jar' from war - Removing file '/WEB-INF/lib/alfresco-device-sync-events-3.2.0.jar' from war - Removing file '/WEB-INF/classes/alfresco/subsystems/Events/default/sync-events-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/extension/subsystems/Messaging/default/default/sync-messaging-override-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/extension/templates/webscripts/org/alfresco/repo/sync/api/syncconfig.get.desc.xml' from war - Removing file '/WEB-INF/classes/alfresco/extension/templates/webscripts/org/alfresco/repo/sync/api/synctxns.post.desc.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/model/device-sync-model.properties' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/model/deviceSyncModel.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/model/model-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/org.alfresco.repo.domain.dialect.DB2Dialect/device-sync-txns-SqlMap.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/org.alfresco.repo.domain.dialect.Oracle9Dialect/device-sync-txns-SqlMap.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/org.alfresco.repo.domain.dialect.SQLServerDialect/device-sync-txns-SqlMap.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/org.alfresco.repo.domain.dialect.Dialect/device-sync-txns-SqlMap.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/org.alfresco.repo.domain.dialect.Dialect/device-sync-SqlMap.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/deviceSync-SqlMapConfig.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/metrics-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/log4j.properties' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/sync-api-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/jmx-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/module-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/sync-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/alfresco-global.properties' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/sync-config-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/dao-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/sync-filter-context.xml' from war - Removing file '/WEB-INF/classes/alfresco/subsystems/Events/default' from war - Removing file '/WEB-INF/classes/alfresco/subsystems/Events' from war - Removing file '/WEB-INF/classes/alfresco/extension/subsystems/Messaging/default/default' from war - Removing file '/WEB-INF/classes/alfresco/extension/subsystems/Messaging/default' from war - Removing file '/WEB-INF/classes/alfresco/extension/subsystems/Messaging' from war - Removing file '/WEB-INF/classes/alfresco/extension/subsystems' from war - Removing file '/WEB-INF/classes/alfresco/extension/templates/webscripts/org/alfresco/repo/sync/api' from war - Removing file '/WEB-INF/classes/alfresco/extension/templates/webscripts/org/alfresco/repo/sync' from war - Removing file '/WEB-INF/classes/alfresco/extension/templates/webscripts/org/alfresco/repo' from war - Removing file '/WEB-INF/classes/alfresco/extension/templates/webscripts/org/alfresco' from war - Removing file '/WEB-INF/classes/alfresco/extension/templates/webscripts/org' from war - Removing file '/WEB-INF/classes/alfresco/extension/templates/webscripts' from war - Removing file '/WEB-INF/classes/alfresco/extension/templates' from war - Removing file '/WEB-INF/classes/alfresco/extension' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/model' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/org.alfresco.repo.domain.dialect.DB2Dialect' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/org.alfresco.repo.domain.dialect.Oracle9Dialect' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/org.alfresco.repo.domain.dialect.SQLServerDialect' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis/org.alfresco.repo.domain.dialect.Dialect' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/ibatis' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/modifications.install' from war - Removing file '/WEB-INF/classes/alfresco/module/org_alfresco_device_sync_repo/module.properties' from war Adding files relating to version '3.2.0' of module 'org_alfresco_device_sync_repo' [91m11060000 An IO error was encountered during deployment of the AMP into the WAR
I think a ticket should be raised to debug and fix this issue.
Steps to reproduce:
1- Get the standards SDK4.0 archetype by using mvn archetype:generate -Dfilter=org.alfresco:
2- Select All in one project
3- Once project is ready, execute ./run.bat build_start command.
Sample project is available here where i was able to replicate the issue: https://github.com/abhinavmishra14/AIO-ACS6.2.0-Build-Issue
Expected: It should start the containers as usual.
Actual: Build fails with an error while installing the amps. error: [91m11060000 An IO error was encountered during deployment of the AMP into the WAR
Full Log is available here (Not allowed to attach a text file, so uploaded in github):
https://github.com/abhinavmishra14/AIO-ACS6.2.0-Build-Issue/blob/master/aio-test/buildlog-6.2.0.txt
When i reverted back to 6.1.0.5 version, it works perfectly fine:
<!-- ACS and Share Enterprise version configuration ########################## [Start] -->
<alfresco.bomDependencyArtifactId>acs-packaging</alfresco.bomDependencyArtifactId>
<alfresco.platform.version>6.1.0.5</alfresco.platform.version>
<alfresco.share.version>6.1.0</alfresco.share.version>
<docker.acs.image>alfresco/alfresco-content-repository</docker.acs.image>
<docker.share.image>alfresco/alfresco-share</docker.share.image>
<!-- ACS and Share Enterprise version configuration ########################## [End] -->
Here is the full log:
12-11-2019 08:36 AM
Abhinav have you heard anything from Alfresco on this?
I opened an issue in the Github SDK project a week ago, but no response:
Explore our Alfresco products with the links below. Use labels to filter content by product module.