Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
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
37 changes: 21 additions & 16 deletions .github/workflows/ci_main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
run: ./mvnw dependency:go-offline -U -B

- name: Build with Maven
run: ./mvnw package -DskipUnitTests -B
run: ./mvnw package -DskipTests=true -B

unit-tests:
needs: package
Expand All @@ -57,8 +57,14 @@ jobs:
key: confapi-plugin-${{ hashFiles('**/pom.xml') }}
restore-keys: confapi-plugin

- name: Run Unit Tests and analyze on SonarCloud
run: ./mvnw test sonar:sonar -B
- name: Run Unit Tests
run: ./mvnw --batch-mode compile test

- name: Perform static code analysis
run: |
./mvnw --batch-mode sonar:sonar \
--settings ./.github/workflows/settings.xml \
-P resolving,analyzing,defaults

integration-tests:
needs: package
Expand All @@ -82,21 +88,19 @@ jobs:
restore-keys: confapi-plugin

- name: Run Integration Tests
run: ./mvnw integration-test -DskipUnitTests -B
run: ./mvnw integration-test -B

deploy:
needs: [unit-tests, integration-tests]

runs-on: ubuntu-20.04

env:
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
GPG_KEY_BASE64: ${{ secrets.GPG_KEY_BASE64 }}
GPG_KEY_NAME: ${{ secrets.GPG_KEY_NAME }}
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
SIGN_ASC_SALT: ${{ secrets.SIGN_ASC_SALT }}
SIGN_ASC_KEY: ${{ secrets.SIGN_ASC_KEY }}
SIGN_ASC_IV: ${{ secrets.SIGN_ASC_IV }}

steps:
- name: Set up JDK 11
Expand All @@ -114,14 +118,15 @@ jobs:
key: confapi-plugin-${{ hashFiles('**/pom.xml') }}
restore-keys: confapi-plugin

- name: Decrypt Signing Key
run: openssl aes-256-cbc -S ${SIGN_ASC_SALT} -K ${SIGN_ASC_KEY} -iv ${SIGN_ASC_IV} -in .github/workflows/sign.asc.enc -out .github/workflows/sign.asc -d

- name: Import Signing Key
run: gpg --no-tty --batch --import .github/workflows/sign.asc
- name: Import GPG key
run: echo "${GPG_KEY_BASE64}" | base64 --decode | gpg --no-tty --batch --import

- name: Deploy to Maven Central
run: export GPG_TTY=$(tty) && ./mvnw -s .github/workflows/settings.xml -DskipTests deploy -B
- name: Publish
run: |
./mvnw --batch-mode deploy \
--settings ./.github/workflows/settings.xml \
-P resolving,signing,deploying,defaults \
-DskipTests=true

apcc:
needs: deploy
Expand Down
14 changes: 10 additions & 4 deletions .github/workflows/ci_pull_request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
run: ./mvnw dependency:go-offline -U -B

- name: Build with Maven
run: ./mvnw package -DskipUnitTests -B
run: ./mvnw package -DskipTests=true -B

unit-tests:
needs: package
Expand All @@ -57,8 +57,14 @@ jobs:
key: confapi-plugin-${{ hashFiles('**/pom.xml') }}
restore-keys: confapi-plugin

- name: Run Unit Tests and analyze on SonarCloud
run: ./mvnw test sonar:sonar -B
- name: Run Unit Tests
run: ./mvnw --batch-mode compile test

- name: Perform static code analysis
run: |
./mvnw --batch-mode sonar:sonar \
--settings ./.github/workflows/settings.xml \
-P resolving,analyzing,defaults

integration-tests:
needs: package
Expand All @@ -82,7 +88,7 @@ jobs:
restore-keys: confapi-plugin

- name: Run Integration Tests
run: ./mvnw integration-test -DskipUnitTests -B
run: ./mvnw integration-test -DskipTests=true -B

apcc:
needs: package
Expand Down
32 changes: 21 additions & 11 deletions .github/workflows/settings.xml
Original file line number Diff line number Diff line change
@@ -1,28 +1,38 @@
<settings>

<servers>
<server>
<id>sonatype-nexus-snapshots</id>
<username>${env.OSSRH_USERNAME}</username>
<password>${env.OSSRH_PASSWORD}</password>
</server>
<server>
<id>sonatype-nexus-staging</id>
<id>ossrh</id>
<username>${env.OSSRH_USERNAME}</username>
<password>${env.OSSRH_PASSWORD}</password>
</server>
</servers>

<profiles>
<profile>
<id>sign-env</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<id>analyzing</id>
<properties>
<sonar.projectKey>aservo_ldap-crowd-adapter</sonar.projectKey>
<sonar.organization>800c9135c81800959e51375f6594c91a1f757be9bbbc14d311783a4f75c501ec7807da061e787a9ea89433eb1cf2d6088b664332abd6a411ca5b44e811e97a23</sonar.organization>
<sonar.host.url>https://sonarcloud.io</sonar.host.url>
</properties>
</profile>
<profile>
<id>signing</id>
<properties>
<gpg.executable>gpg</gpg.executable>
<gpg.keyname>${env.GPG_KEY_NAME}</gpg.keyname>
<gpg.passphrase>${env.GPG_PASSPHRASE}</gpg.passphrase>
<gpg.executable>gpg</gpg.executable>
</properties>
</profile>
<profile>
<id>deploying</id>
<properties>
<nexus.host.url>https://oss.sonatype.org/</nexus.host.url>
<nexus.snapshot.url>https://oss.sonatype.org/content/repositories/snapshots</nexus.snapshot.url>
<nexus.release.url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</nexus.release.url>
</properties>
</profile>
</profiles>

</settings>
Binary file removed .github/workflows/sign.asc.enc
Binary file not shown.
30 changes: 30 additions & 0 deletions index.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -2613,6 +2613,36 @@ endif::internal-generation[]
|
| date-time

| server
|
| DirectoryLdapServer
|
|

| permissions
|
| DirectoryLdapPermissions
|
|

| advanced
|
| DirectoryInternalAdvanced
|
|

| credentialPolicy
|
| DirectoryInternalCredentialPolicy
|
|

| schema
|
| DirectoryLdapSchema
|
|

|===


Expand Down
16 changes: 13 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>de.aservo</groupId>
<artifactId>parent-pom</artifactId>
<version>0.0.11</version>
<version>1.0.0-SNAPSHOT</version>
</parent>

<modelVersion>4.0.0</modelVersion>
Expand Down Expand Up @@ -53,6 +53,16 @@
</developers>

<properties>
<!-- default properties -->
<java.version>1.8</java.version>
<maven.compiler.target>${java.version}</maven.compiler.target>
<maven.compiler.source>${java.version}</maven.compiler.source>
<!-- Atlassia SDK settings -->
<downloadSources>true</downloadSources>
<downloadJavadocs>true</downloadJavadocs>
<allow.google.tracking>false</allow.google.tracking>
<skipAllPrompts>true</skipAllPrompts>
<!-- Jira related properties -->
<jira.version>8.15.0</jira.version>
<jira.data.version>8.12.1</jira.data.version>
<!-- other properties -->
Expand Down Expand Up @@ -379,7 +389,7 @@
<plugin>
<groupId>io.swagger.core.v3</groupId>
<artifactId>swagger-maven-plugin</artifactId>
<version>${swagger.version}</version>
<version>${swagger.plugin.version}</version>
<configuration>
<openapiFilePath>${basedir}/src/main/resources/openapi.yaml</openapiFilePath>
<resourcePackages>
Expand All @@ -402,7 +412,7 @@
<plugin>
<groupId>org.openapitools</groupId>
<artifactId>openapi-generator-maven-plugin</artifactId>
<version>${openapi-generator-maven-plugin.version}</version>
<version>${openapi-generator.plugin.version}</version>
<executions>
<execution>
<phase>package</phase>
Expand Down