Alfresco / alfresco-sdk

The Alfresco In-Process SDK is based on Apache Maven, includes support for rapid and standard development, testing, packaging, versioning and release of your Alfresco integration and extension projects
Apache License 2.0
185 stars 113 forks source link

Feature: build and execute with Alfresco Enterprise version applying a maven profile #553

Closed luisfernandezprado closed 5 years ago

luisfernandezprado commented 5 years ago

I'm submitting a feature

[ ] bug report => search github for a similar issue or PR before submitting
[X ] feature request

Possiblity to build and run Alfresco with a enterprise version, with only apply a maven profile

Expected Behavior

When I run the script "run.bat", if I include the argument "enterprise" at the end, the script execute the maven build with the profile "enterprise" and the versions of Alfresco docker image using the enterprise version. Example: run.bat build_start enterprise

Current Behavior

Right now, when a project based on the alfresco-platform-jar-archetype is created, it comes with all the configuration properties configured to be executed with a community version and the only way to execute a Enterprise version is overwrite the existing properties.

Possible Solution

Include a profile in the pom of the proyect with ID "enterprise"

<profiles>
    <profile>
            <id>enterprise</id>
            <properties>
            <alfresco.bomDependencyArtifactId>acs-packaging</alfresco.bomDependencyArtifactId>
            <alfresco.platform.version>6.0.1.1</alfresco.platform.version>
            <alfresco.share.version>6.0.1.1</alfresco.share.version>

            <docker.acs.image>alfresco/alfresco-content-repository</docker.acs.image>
            <docker.share.image>alfresco/alfresco-share</docker.share.image>

            <alfresco.remote.api.artifact.id>alfresco-enterprise-remote-api</alfresco.remote.api.artifact.id>
            </properties>
    </profile>
</profiles>

On the other hand, include in the run scripts the option to add the profile in the execution to execute with enterprise version, using the following format for example: run.bat build_start enterprise

Steps to Reproduce (for bugs)

1. 2. 3. 4. 5.

Context

Your Environment

Additional information

ohej commented 5 years ago

We are not planning to provide profiles to switch between community and enterprise by default.

Running with enterprise can easily be changes via properties (which can also be overridden from the commandline) but it could also require changes to the docker compose file.

We have sufficient documentation on how to work with enterprise (https://github.com/Alfresco/alfresco-sdk/tree/sdk-4.0/docs/advanced-topics/working-with-enterprise).