Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable profile "cloud" by default #3208

Merged
merged 4 commits into from
Nov 15, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
# always act on the modified source code (even for event pull_request_target)
# is considered potentially unsafe (https://securitylab.github.com/research/github-actions-preventing-pwn-requests/) but actions are only executed after approval from committers
with:
Expand All @@ -55,7 +55,7 @@ jobs:
persist-credentials: false

- name: Set up JDK
uses: actions/setup-java@v2
uses: actions/setup-java@v3
with:
cache: 'maven'
# Adobe is moving away from Azul Zulu to Oracle JDK (which is not an option) - Eclipse Temurin is suggested as the "closest thing"
Expand Down Expand Up @@ -88,9 +88,6 @@ jobs:
- name: ${{ matrix.namePrefix }} Build with Maven ${{ env.STEP_NAME_SUFFIX }}
run: mvn -e -B -V ${{ env.MVN_GOAL }} ${{ env.MVN_ADDITIONAL_OPTS }}

- name: ${{ matrix.namePrefix }} Build cloud all package with Maven ${{ env.STEP_NAME_SUFFIX }}
run: mvn -e -B -V -pl all -P cloud ${{ env.MVN_GOAL }} ${{ env.MVN_ADDITIONAL_OPTS }}

- name: Publish Test Report
if: ${{ always() }} # make sure to run even if previous Maven execution failed (due to failed test)
uses: scacap/action-surefire-report@v1
Expand Down
29 changes: 8 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
# ACS AEM Commons

[![Maven Central](https://img.shields.io/maven-central/v/com.adobe.acs/acs-aem-commons-all)](https://central.sonatype.com/artifact/com.adobe.acs/acs-aem-commons-all)
[![Join the chat at https://gitter.im/Adobe-Consulting-Services/acs-aem-commons](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/Adobe-Consulting-Services/acs-aem-commons?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)

[![Build Status](https://github.com/Adobe-Consulting-Services/acs-aem-commons/actions/workflows/maven.yml/badge.svg)](https://github.com/Adobe-Consulting-Services/acs-aem-commons/actions)

[![Code Climate Issues](https://img.shields.io/codeclimate/issues/Adobe-Consulting-Services/acs-aem-commons.svg)](https://codeclimate.com/github/Adobe-Consulting-Services/acs-aem-commons)

[![codecov](https://codecov.io/gh/Adobe-Consulting-Services/acs-aem-commons/branch/master/graph/badge.svg?token=KkCffH5xs4)](https://codecov.io/gh/Adobe-Consulting-Services/acs-aem-commons)

[![Maintainability](https://api.codeclimate.com/v1/badges/a1038e3e7f9c90dcaaa6/maintainability)](https://codeclimate.com/github/Adobe-Consulting-Services/acs-aem-commons/maintainability)

This project is a unified collection of AEM/CQ code generated by the AEM consulting practice.
Expand All @@ -16,21 +13,23 @@ This project is a unified collection of AEM/CQ code generated by the AEM consult

This project uses Maven for building. Common commands:

From the root directory, run ``mvn -PautoInstallPackage clean install`` to build the bundle and content package and install to a CQ instance.
From the root directory, run `mvn -PautoInstallPackage clean install` to build the bundle and content package and install to an AEM instance.

From the bundle directory, run `mvn -PautoInstallBundle clean install` to build *just* the bundle and install to a CQ instance.

From the bundle directory, run ``mvn -PautoInstallBundle clean install`` to build *just* the bundle and install to a CQ instance.
The Maven profile `cloud` is used to both build and deploy the version targeted for AEMaaCS. To build and deploy the version for AEM 6.5.x use the command line option `-P \!cloud` [to deactivate the profile `cloud`](https://maven.apache.org/guides/introduction/introduction-to-profiles.html#deactivating-a-profile).

## Using with VLT

To use vlt with this project, first build and install the package to your local CQ instance as described above. Then cd to `content/src/main/content/jcr_root` and run
To use vlt with this project, first build and install the package to your local AEM instance as described above. Then cd to `content/src/main/content/jcr_root` and run

vlt --credentials admin:admin checkout -f ../META-INF/vault/filter.xml --force http://localhost:4502/crx

Once the working copy is created, you can use the normal ``vlt up`` and ``vlt ci`` commands.

## Specifying CRX Host/Port
## Specifying AEM Host/Port

The CRX host and port can be specified on the command line with:
The AEM host and port can be specified on the command line with:
mvn -Dcrx.host=otherhost -Dcrx.port=5502 <goals>

## Distribution
Expand All @@ -48,15 +47,3 @@ Watch this space.
## Want commit rights?

* Create an issue.



mvn -B org.apache.maven.plugins:maven-archetype-plugin:3.2.1:generate \
-D archetypeGroupId=com.adobe.aem \
-D archetypeArtifactId=aem-project-archetype \
-D archetypeVersion=36\
-D appTitle="My Site" \
-D appId="acs-aem-commons" \
-D groupId="com.adobe.acs"


3 changes: 0 additions & 3 deletions all/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -232,9 +232,6 @@

<profile>
<id>cloud</id>
<activation>
<activeByDefault>false</activeByDefault>
</activation>
<properties>
<contentPackageFile>${project.build.directory}/${project.build.finalName}-cloud.zip</contentPackageFile>
</properties>
Expand Down
6 changes: 4 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -893,10 +893,13 @@ Service-Component: OSGI-INF/*.xml
</build>
</profile>

<!-- enable this profile to additionally build the packages/bundles for AEMaaCS,
<!-- disable this profile to not build/deploy the packages/bundles for AEMaaCS,
the ones for AEM on prem are always built -->
<profile>
<id>cloud</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<modules>
<module>bundle-cloud</module>
</modules>
Expand All @@ -913,7 +916,6 @@ Service-Component: OSGI-INF/*.xml

<modules>
<module>bundle</module>
<module>bundle-cloud</module>
<module>oakpal-checks</module>
<module>ui.apps</module>
<module>ui.content</module>
Expand Down
Loading