You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by il...@apache.org on 2020/03/15 16:26:37 UTC
[syncope] branch SYNCOPE-1545 updated: [SYNCOPE-1545] Archetype
This is an automated email from the ASF dual-hosted git repository.
ilgrosso pushed a commit to branch SYNCOPE-1545
in repository https://gitbox.apache.org/repos/asf/syncope.git
The following commit(s) were added to refs/heads/SYNCOPE-1545 by this push:
new 264b270 [SYNCOPE-1545] Archetype
264b270 is described below
commit 264b270f3b938e35408b976e59169faf7557cead
Author: Francesco Chicchiriccò <il...@apache.org>
AuthorDate: Sun Mar 15 17:26:24 2020 +0100
[SYNCOPE-1545] Archetype
---
archetype/pom.xml | 32 +++++
.../META-INF/maven/archetype-metadata.xml | 13 ++
.../main/resources/archetype-resources/fit/pom.xml | 12 +-
.../main/resources/archetype-resources/wa/pom.xml | 134 +++++++++++++++++++++
.../wa/src/test/resources/keymaster.properties | 19 +++
archetype/src/main/resources/meta-pom.xml | 7 ++
6 files changed, 216 insertions(+), 1 deletion(-)
diff --git a/archetype/pom.xml b/archetype/pom.xml
index 54a749a..f500f59 100644
--- a/archetype/pom.xml
+++ b/archetype/pom.xml
@@ -354,6 +354,38 @@ under the License.
<include>keymaster.properties</include>
</includes>
</resource>
+
+ <resource>
+ <directory>../wa/src/main/resources</directory>
+ <targetPath>${project.build.outputDirectory}/archetype-resources/wa/src/main/resources</targetPath>
+ </resource>
+ <resource>
+ <directory>../wa/src/test/resources</directory>
+ <targetPath>${project.build.outputDirectory}/archetype-resources/wa/src/main/resources</targetPath>
+ <includes>
+ <include>keymaster.properties</include>
+ </includes>
+ </resource>
+ <resource>
+ <directory>../fit/wa-reference/src/main/resources</directory>
+ <targetPath>${project.build.outputDirectory}/archetype-resources/wa/src/main/resources</targetPath>
+ <includes>
+ <include>application-embedded.properties</include>
+ <include>log4j2.xml</include>
+ </includes>
+ </resource>
+ <resource>
+ <directory>../fit/wa-reference/src/main/resources</directory>
+ <targetPath>${project.build.outputDirectory}/archetype-resources/wa/src/test/resources</targetPath>
+ <includes>
+ <include>wa</include>
+ <include>keymaster.properties</include>
+ </includes>
+ </resource>
+ <resource>
+ <directory>../fit/wa-reference/src/main/webapp/WEB-INF</directory>
+ <targetPath>${project.build.outputDirectory}/archetype-resources/wa/src/main/webapp/WEB-INF</targetPath>
+ </resource>
</resources>
</build>
diff --git a/archetype/src/main/resources/META-INF/maven/archetype-metadata.xml b/archetype/src/main/resources/META-INF/maven/archetype-metadata.xml
index f22b5fb..9fa586c 100644
--- a/archetype/src/main/resources/META-INF/maven/archetype-metadata.xml
+++ b/archetype/src/main/resources/META-INF/maven/archetype-metadata.xml
@@ -79,6 +79,19 @@ under the License.
</fileSet>
</fileSets>
</module>
+ <module id="syncope-wa" dir="wa" name="syncope-wa">
+ <fileSets>
+ <fileSet filtered="false" encoding="UTF-8">
+ <directory>src/main/resources</directory>
+ </fileSet>
+ <fileSet filtered="false" encoding="UTF-8">
+ <directory>src/main/webapp</directory>
+ </fileSet>
+ <fileSet filtered="false" encoding="UTF-8">
+ <directory>src/test/resources</directory>
+ </fileSet>
+ </fileSets>
+ </module>
<module id="syncope-sra" dir="sra" name="syncope-sra">
<fileSets>
<fileSet filtered="false" encoding="UTF-8">
diff --git a/archetype/src/main/resources/archetype-resources/fit/pom.xml b/archetype/src/main/resources/archetype-resources/fit/pom.xml
index 53745a8..6be3d9d 100644
--- a/archetype/src/main/resources/archetype-resources/fit/pom.xml
+++ b/archetype/src/main/resources/archetype-resources/fit/pom.xml
@@ -153,6 +153,10 @@ under the License.
<copy file="../enduser/target/test-classes/customTemplate.json"
todir="../enduser/target/syncope-enduser/WEB-INF/classes"
overwrite="true"/>
+
+ <copy file="../wa/target/test-classes/keymaster.properties"
+ todir="../wa/target/syncope-wa/WEB-INF/classes"
+ overwrite="true"/>
</target>
</configuration>
<goals>
@@ -181,7 +185,7 @@ under the License.
<goal>exec</goal>
</goals>
<configuration>
- <executable>java</executable>
+ <executable>${JAVA_HOME}/bin/java</executable>
<arguments>
<argument>-jar</argument>
<argument>${basedir}/../sra/target/syncope-sra.jar</argument>
@@ -253,6 +257,12 @@ under the License.
<context>syncope-enduser</context>
</properties>
</deployable>
+ <deployable>
+ <location>../wa/target/syncope-wa</location>
+ <properties>
+ <context>syncope-wa</context>
+ </properties>
+ </deployable>
</deployables>
</configuration>
</plugin>
diff --git a/archetype/src/main/resources/archetype-resources/wa/pom.xml b/archetype/src/main/resources/archetype-resources/wa/pom.xml
new file mode 100644
index 0000000..91b4a22
--- /dev/null
+++ b/archetype/src/main/resources/archetype-resources/wa/pom.xml
@@ -0,0 +1,134 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you 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/xsd/maven-4.0.0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>${groupId}</groupId>
+ <artifactId>${rootArtifactId}</artifactId>
+ <version>${version}</version>
+ </parent>
+
+ <name>Apache Syncope sample project - WA</name>
+ <groupId>${groupId}</groupId>
+ <artifactId>${artifactId}</artifactId>
+ <packaging>war</packaging>
+
+ <properties>
+ <guava.version>28.2-jre</guava.version>
+ <opensaml.version>3.4.5</opensaml.version>
+ <bootstrap.version>4.4.1</bootstrap.version>
+ <slf4j.version>2.0.0-alpha1</slf4j.version>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>${groupId}</groupId>
+ <artifactId>syncope-common</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.syncope</groupId>
+ <artifactId>syncope-wa</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.syncope.ext.self-keymaster</groupId>
+ <artifactId>syncope-ext-self-keymaster-client</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.syncope.common.keymaster</groupId>
+ <artifactId>syncope-common-keymaster-client-zookeeper</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <finalName>syncope-wa</finalName>
+
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-war-plugin</artifactId>
+ <inherited>true</inherited>
+ <configuration>
+ <webResources>
+ <resource>
+ <directory>${basedir}/src/main/webapp/WEB-INF</directory>
+ <filtering>true</filtering>
+ <targetPath>WEB-INF</targetPath>
+ <includes>
+ <include>web.xml</include>
+ </includes>
+ </resource>
+ </webResources>
+ </configuration>
+ </plugin>
+ </plugins>
+
+ <resources>
+ <resource>
+ <directory>src/main/resources</directory>
+ <filtering>true</filtering>
+ </resource>
+ </resources>
+
+ <testResources>
+ <testResource>
+ <directory>src/test/resources</directory>
+ <filtering>true</filtering>
+ </testResource>
+ </testResources>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>executable</id>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.springframework.boot</groupId>
+ <artifactId>spring-boot-starter-undertow</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.springframework.boot</groupId>
+ <artifactId>spring-boot-maven-plugin</artifactId>
+ <configuration>
+ <mainClass>org.apache.syncope.wa.SyncopeWAApplication</mainClass>
+ <layout>ZIP</layout>
+ </configuration>
+ <executions>
+ <execution>
+ <goals>
+ <goal>repackage</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+</project>
diff --git a/archetype/src/main/resources/archetype-resources/wa/src/test/resources/keymaster.properties b/archetype/src/main/resources/archetype-resources/wa/src/test/resources/keymaster.properties
new file mode 100644
index 0000000..033fe3b
--- /dev/null
+++ b/archetype/src/main/resources/archetype-resources/wa/src/test/resources/keymaster.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you 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.
+keymaster.address=http://localhost:9080/syncope/rest/keymaster
+keymaster.username=${anonymousUser}
+keymaster.password=${anonymousKey}
diff --git a/archetype/src/main/resources/meta-pom.xml b/archetype/src/main/resources/meta-pom.xml
index 8eb4a43..fe5f3e8 100644
--- a/archetype/src/main/resources/meta-pom.xml
+++ b/archetype/src/main/resources/meta-pom.xml
@@ -89,6 +89,12 @@ under the License.
</dependency>
<dependency>
+ <groupId>org.apache.syncope</groupId>
+ <artifactId>syncope-wa</artifactId>
+ <version>${syncope.version}</version>
+ </dependency>
+
+ <dependency>
<groupId>org.apache.syncope.ext.self-keymaster</groupId>
<artifactId>syncope-ext-self-keymaster-rest-cxf</artifactId>
<version>${syncope.version}</version>
@@ -135,6 +141,7 @@ under the License.
<module>console</module>
<module>enduser</module>
<module>sra</module>
+ <module>wa</module>
<module>fit</module>
</modules>