Skip to content

Commit

Permalink
Extract OSGI configuration to new package ui.config
Browse files Browse the repository at this point in the history
  • Loading branch information
szmeagol committed Sep 26, 2024
1 parent 3589f22 commit 2c7dbc4
Show file tree
Hide file tree
Showing 19 changed files with 455 additions and 5 deletions.
24 changes: 23 additions & 1 deletion all/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
<artifactId>acs-aem-commons-all</artifactId>
<name>ACS AEM Commons Container Package (All)</name>
<description>ACS AEM Commons container content package which delivers acs-aem-commons-ui.apps,
acs-aem-commons-ui.content, the OSGi bundle and configuration.
acs-aem-commons-ui.content, acs-aem-commons-ui.config and the OSGi bundle.
</description>
<packaging>content-package</packaging>

Expand All @@ -47,6 +47,7 @@
<inherited>false</inherited>
<configuration>
<packageType>container</packageType>
<jcrRootSourceDirectory>none</jcrRootSourceDirectory>
</configuration>
<executions>
<execution>
Expand Down Expand Up @@ -86,6 +87,13 @@
<filter>true</filter>
<isAllVersionsFilter>true</isAllVersionsFilter>
</embedded>
<embedded>
<groupId>${project.groupId}</groupId>
<artifactId>acs-aem-commons-ui.config</artifactId>
<target>/apps/acs-commons/install</target>
<filter>true</filter>
<isAllVersionsFilter>true</isAllVersionsFilter>
</embedded>
</embeddeds>
</configuration>
</execution>
Expand Down Expand Up @@ -210,6 +218,13 @@
<type>zip</type>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>acs-aem-commons-ui.config</artifactId>
<version>${project.version}</version>
<type>zip</type>
<scope>provided</scope>
</dependency>
</dependencies>

<profiles>
Expand Down Expand Up @@ -292,6 +307,13 @@
<filter>true</filter>
<isAllVersionsFilter>true</isAllVersionsFilter>
</embedded>
<embedded>
<groupId>${project.groupId}</groupId>
<artifactId>acs-aem-commons-ui.config</artifactId>
<target>/apps/acs-commons/install</target>
<filter>true</filter>
<isAllVersionsFilter>true</isAllVersionsFilter>
</embedded>
</embeddeds>
</configuration>
</execution>
Expand Down
5 changes: 1 addition & 4 deletions all/src/main/content/META-INF/vault/filter.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,5 @@
-->

<workspaceFilter version="1.0">
<filter root="/apps/acs-commons/config"/>
<filter root="/apps/acs-commons/config.author"/>
<filter root="/apps/acs-commons/config.publish"/>
<filter root="/apps/acs-commons/config.rde" type="cleanup"/>
<filter root="/apps/acs-commons/install"/>
</workspaceFilter>
1 change: 1 addition & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -943,6 +943,7 @@ Bundle-DocURL: https://adobe-consulting-services.github.io/acs-aem-commons/
<module>oakpal-checks</module>
<module>ui.apps</module>
<module>ui.content</module>
<module>ui.config</module>
<module>all</module>
</modules>
</project>
1 change: 1 addition & 0 deletions ui.config/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/nbactions-autoInstallPackage.xml
170 changes: 170 additions & 0 deletions ui.config/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,170 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ ACS AEM Commons
~
~ Copyright (C) 2013 - 2023 Adobe
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<!-- ====================================================================== -->
<!-- P A R E N T P R O J E C T D E S C R I P T I O N -->
<!-- ====================================================================== -->
<parent>
<groupId>com.adobe.acs</groupId>
<artifactId>acs-aem-commons</artifactId>
<version>6.6.5-SNAPSHOT</version>
</parent>

<!-- ====================================================================== -->
<!-- P R O J E C T D E S C R I P T I O N -->
<!-- ====================================================================== -->

<artifactId>acs-aem-commons-ui.config</artifactId>
<name>ACS AEM Commons UI.Config Package</name>
<description>ACS AEM Commons content package containing configs.</description>
<packaging>content-package</packaging>

<build>

<plugins>
<plugin>
<groupId>org.apache.jackrabbit</groupId>
<artifactId>filevault-package-maven-plugin</artifactId>
<configuration>
<packageType>container</packageType>
</configuration>
</plugin>

<plugin>
<groupId>net.adamcin.oakpal</groupId>
<artifactId>oakpal-maven-plugin</artifactId>
<configuration>
<deferBuildFailure>true</deferBuildFailure>
<checklists>
<checklist>acs-internal</checklist>
</checklists>

<!-- Enforce separation of content and code (CODE ONLY) -->
<checks>
<check>
<name>basic/paths</name>
<config>
<rules>
<rule>
<pattern>/apps(/.*)?</pattern>
<type>allow</type>
</rule>
</rules>
</config>
</check>
</checks>

<websterTargets>
<nodetypes />
<privileges />
</websterTargets>
</configuration>
<executions>
<execution>
<id>oakpal-scan</id>
<goals>
<goal>scan</goal>
</goals>
</execution>
<execution>
<id>oakpal-scan-content-class-aem65</id>
<goals>
<goal>scan</goal>
</goals>
<configuration>
<summaryFile>${project.build.directory}/oakpal-plugin/reports/content-class-aem65.json
</summaryFile>
<checklists>
<checklist>content-class-aem65</checklist>
</checklists>
</configuration>
</execution>
<execution>
<id>oakpal-verify</id>
<goals>
<goal>verify</goal>
</goals>
<configuration>
<summaryFiles>
<summaryFile>${project.build.directory}/oakpal-plugin/reports/content-class-aem65.json
</summaryFile>
</summaryFiles>
</configuration>
</execution>
</executions>
</plugin>

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>license-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/*.xml</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>acs-aem-commons-oakpal-checks</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.adobe.acs</groupId>
<artifactId>acs-aem-commons-bundle</artifactId>
<scope>provided</scope>
</dependency>
<!-- put UberJar last so that more specific artifacts take precedence -->
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>uber-jar</artifactId>
<scope>provided</scope>
</dependency>
</dependencies>
<profiles>
<profile>
<id>autoInstallUiConfigPackage</id>
<build>
<plugins>
<plugin>
<groupId>com.day.jcr.vault</groupId>
<artifactId>content-package-maven-plugin</artifactId>
<configuration>
<packageFile>${contentPackageFile}</packageFile>
</configuration>
<executions>
<execution>
<id>install-content-package</id>
<phase>install</phase>
<goals>
<goal>install</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>
25 changes: 25 additions & 0 deletions ui.config/src/main/content/META-INF/vault/filter.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ ACS AEM Commons
~
~ Copyright (C) 2013 - 2023 Adobe
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->

<workspaceFilter version="1.0">
<filter root="/apps/acs-commons/config"/>
<filter root="/apps/acs-commons/config.author"/>
<filter root="/apps/acs-commons/config.publish"/>
<filter root="/apps/acs-commons/config.rde" type="cleanup"/>
</workspaceFilter>
15 changes: 15 additions & 0 deletions ui.config/src/main/resources/META-INF/COPYRIGHT
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
Copyright 2013 Adobe

Adobe holds the copyright for all the files found in this repository.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Loading

0 comments on commit 2c7dbc4

Please sign in to comment.