diff --git a/.github/workflows/deploy-maven.yml b/.github/workflows/deploy-maven.yml
new file mode 100644
index 0000000..fe34be1
--- /dev/null
+++ b/.github/workflows/deploy-maven.yml
@@ -0,0 +1,33 @@
+name: Publish package to the Maven Central Repository
+on:
+ release:
+ types: [created]
+jobs:
+ publish:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v2
+ - name: Set up Maven Central Repository
+ uses: actions/setup-java@v1
+ with:
+ java-version: 11
+ server-id: ossrh
+ server-username: MAVEN_USERNAME
+ server-password: MAVEN_PASSWORD
+ - id: install-secret-key
+ name: Install gpg secret key
+ run: |
+ cat <(echo -e "${{ secrets.OSSRH_GPG_KEY }}") | gpg --batch --import
+ gpg --list-secret-keys --keyid-format LONG
+ - id: publish-to-central
+ name: Publish to Central Repository
+ env:
+ MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }}
+ MAVEN_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
+ run: |
+ mvn -B versions:set -DnewVersion=${{ github.event.release.tag_name }}
+ mvn \
+ --no-transfer-progress \
+ --batch-mode \
+ -Dgpg.passphrase=${{ secrets.OSSRH_GPG_KEY_PASSWORD }} \
+ clean deploy
\ No newline at end of file
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index c5194c1..b3f685e 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -25,7 +25,7 @@ jobs:
restore-keys: ${{ runner.os }}-m2
- name: Build project # This would actually build your project, using zip for an example artifact
run: |
- mvn -B versions:set -DnewVersion=${{ github.ref }}
+ mvn -B versions:set -DnewVersion=${{ github.event.release.tag_name }}
mvn -B package
- name: Create Release
id: create_release
@@ -33,8 +33,8 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
- tag_name: ${{ github.ref }}
- release_name: Release ${{ github.ref }}
+ tag_name: ${{ github.event.release.tag_name }}
+ release_name: Release ${{ github.event.release.tag_name }}
draft: false
prerelease: false
- name: Upload Release Asset
@@ -44,6 +44,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
- asset_path: target/keycloak-mail-whitelisting-${{ github.ref }}.jar
- asset_name: keycloak-mail-whitelisting-${{ github.ref }}.jar
+ asset_path: target/keycloak-mail-whitelisting-${{ github.event.release.tag_name }}.jar
+ asset_name: keycloak-mail-whitelisting-${{ github.event.release.tag_name }}.jar
asset_content_type: application/jar
+
diff --git a/pom.xml b/pom.xml
index 6fe1b84..d6c22dc 100644
--- a/pom.xml
+++ b/pom.xml
@@ -2,13 +2,39 @@
4.0.0
net.micedre.keycloak
keycloak-mail-whitelisting
- 1.2-SNAPSHOT
+ 1.3-SNAPSHOT
+
+ Keycloak mail whitelisting extension
+ A keycloak extension to block non authorized domain to register
+ http://github.com/micedre/keycloak-mail-whitelisting
+
+
+ The Apache Software License, Version 2.0
+ http://www.apache.org/licenses/LICENSE-2.0.txt
+
+
+
+
+ Cédric Couralet
+ cedric.couralet@gmail.com
+ https://github.com/micedre
+
+
+
+
+ scm:git:git://github.com/micedre/keycloak-mail-whitelisting.git
+ scm:git:ssh://github.com:micedre/keycloak-mail-whitelisting.git
+ https://github.com/micedre/keycloak-mail-whitelisting/tree/master
+ keycloak-mail-whitelisting-1.2
+
+
UTF-8
1.8
1.8
9.0.3
+
org.keycloak
@@ -45,6 +71,89 @@
false
+
+ org.apache.maven.plugins
+ maven-source-plugin
+ 3.2.1
+
+
+ attach-sources
+
+ jar-no-fork
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-javadoc-plugin
+ 3.2.0
+
+
+ attach-javadocs
+
+ jar
+
+
+
+
+
+
+
+
+ ossrh
+
+ true
+
+
+ gpg
+
+
+
+
+ ossrh
+ Central Repository OSSRH
+ https://s01.oss.sonatype.org/content/repositories/snapshots
+
+
+
+
+
+ org.sonatype.plugins
+ nexus-staging-maven-plugin
+ 1.6.7
+ true
+
+ ossrh
+ https://s01.oss.sonatype.org/
+
+ false
+
+
+
+ org.apache.maven.plugins
+ maven-gpg-plugin
+ 1.6
+
+
+ sign-artifacts
+ verify
+
+ sign
+
+
+
+
+
+ --pinentry-mode
+ loopback
+
+
+
+
+
+
+
\ No newline at end of file