Set up Local AEM Runtime
Adobe Experience Manager (AEM) can be run locally using the AEM as a Cloud Service SDK's QuickStart Jar. This allows developers to deploy to, and test custom code, configuration and content prior to committing it to source control, and deploying it to a AEM as a Cloud Service environment.
Note that ~ is used as shorthand for the User's Directory. In Windows, this is the equivalent of %HOMEPATH% .
Experience Manager is a Java application, and thus requires the Java SDK to support the development tooling.
- Verify Java 11 SDK is installed by running the command:
- Windows: java -version
- macOS / Linux: java --version
Download the AEM as a Cloud Service SDK
The AEM as a Cloud Service SDK, or AEM SDK, contains the QuickStart Jar used to run AEM Author and Publish locally for development, as well as the compatible version of the Dispatcher Tools.
- Log in to downloads.experiencecloud.adobe.com with your Adobe ID
- Note that your Adobe Organization must be provisioned for AEM as a Cloud Service to download the AEM as a Cloud Service SDK.
- Navigate to the AEM as a Cloud Service tab
- Sort by Published Date in Descending order
- Click on the latest AEM SDK result row
- Review and accept the EULA, and tap the Download button
Extract the QuickStart Jar from the AEM SDK zip
- Unzip the downloaded aem-sdk-XXX.zip file
- Ensure your Experience Manager developer license.properties file is available
Note the same QuickStart Jar and license.properties files are used to start both AEM Author and Publish Services.
Set up local AEM Publish Service
The local AEM Publish Service provides developers with the local experience end-users of the AEM will have, such as browsing the Web site hosed on AEM. A local AEM Publish Service is important as it integrates with AEM SDK's Dispatcher tools and allows developers to smoke-test and fine-tune the final end-user facing experience.
- Create the folder ~/aem-sdk/publish
- Copy the QuickStart JAR file to ~/aem-sdk/publish and rename it to aem-publish-p4503.jar
- Copy the license.properties file to ~/aem-sdk/publish
- Start the local AEM Publish Service by either
- Double-clicking the aem-publish-p4503.jar file
- Or executing the java -jar aem-publish-p4503.jar command
- Provide the admin password as admin . Any admin password is acceptable, however its recommend to use the default for local development to reduce the need to re-configure.
- Access the local AEM Publish Service at http://localhost:4503 in a Web browser
$ mkdir -p c:\Users\<My User>\aem-sdk\publish $ copy aem-sdk-quickstart-XXX.jar c:\Users\<My User>\aem-sdk\publish\aem-publish-p4503.jar $ copy ../license.properties c:\Users\<My User>\aem-sdk\publish $ cd c:\Users\<My User>\aem-sdk\publish $ java -jar aem-publish-p4503.jar
macOS / Linux:
$ mkdir -p ~/aem-sdk/publish $ cp aem-sdk-quickstart-XXX.jar ~/aem-sdk/publish/aem-publish-p4503.jar $ cp ../license.properties ~/aem-sdk/publish $ cd ~/aem-sdk/publish $ java -jar aem-publish-p4503.jar
QuickStart Jar start-up modes
The naming of the QuickStart Jar, aem-<tier>_<environment>-p<port number>.jar specifies how it will start up. Once AEM as started in a specific tier, author or publish, it cannot be changed to the alternate tier. To do this, the crx-quickstart folder generated during the first run must be deleted, and QuickStart Jar must be run again. Environment and Ports can be changed, however they require stop/start of the local AEM instance.
Changing environments, dev , stage and prod , can be useful for developers to ensure environment-specific configurations are correctly defined and resolved by AEM. It is recommended that local development primarily be done against the default dev environment run mode.
The available permutations are as follows:
- As Author in Dev run mode on port 4502
- As Author in Dev run mode on port 4502 (same as aem-author-p4502.jar )
- As Author in Staging run mode on port 4502
- As Author in Production run mode on port 4502
- As Author in Dev run mode on port 4503
- As Author in Dev run mode on port 4503 (same as aem-publish-p4503.jar )
- As Author in Staging run mode on port 4503
- As Author in Production run mode on port 4503
Note that the port number can be any available port on the local development machine, however by convention:
- Port 4502 is used for the local AEM Author service
- Port 4503 is used for the local AEM Publish service
Changing these may require adjustments to AEM SDK configurations
When to update the QuickStart Jar
AEM as a Cloud Service releases daily updates, and thus, it is important for local development to be developing against QuickStart Jar version that is "near" to what is deployed to the AEM as Cloud Service environments. It is recommended the local QuickStart Jar used for local development be refreshed at least bi-weekly to match the version of Experience Manager on the Production environment.
Updating the QuickStart Jar to a new version requires replacing the entire local development environment, resulting in a loss of all code, configuration and content in the local AEM repositories. Ensure that any code, config or content that should not be destroyed is safely committed to Git, or exported from the local AEM instance as AEM Packages.
The version of AEM as a Cloud Service can be found via Cloud Manager .
- Cloud Manager > Environments , per environment specified by the AEM Release label