Skip to content

Commit

Permalink
Add a TravisCi file to build on a push to master and release JARs
Browse files Browse the repository at this point in the history
To make these easier to play around with, it would be nice if the
JARs were provided.

This commit adds a `.travis.yml` file that will build the project
and upload all JARs to the github releases page.

You'll need to create a github personal access token with `public_repo`
access and submit this as a secret environment variable on the travis job.

**note:** I commented out anything relating to keycloak-testsuite as I was
unable to find a maven repository serving those dependencies
  • Loading branch information
imduffy15 committed Nov 17, 2019
1 parent 0749265 commit 69def8f
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 10 deletions.
31 changes: 31 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
language: java
jdk:
- openjdk8
branches:
only:
- master
cache:
directories:
- "$HOME/.m2"
before_install:
# - export APP_VERSION="`mvn org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate -Dexpression=project.version | grep -Ev '(^\[|Download\w+:)'`-$TRAVIS_BUILD_NUMBER"
# - echo $APP_VERSION
script:
# - mvn versions:set -DnewVersion=$APP_VERSION
- mvn clean package
before_deploy:
# - git config --global user.email "[email protected]"
# - git config --global user.name "Travis CI"
# - git commit -a -m "Set version to $APP_VERSION"
# - git tag $APP_VERSION -a -m "Generated tag from TravisCI for $APP_VERSION"
# - git push -q -f https://[email protected]/imduffy15/keycloak-extension-playground --tags
deploy:
skip_cleanup: true
provider: releases
api_key: $GITHUB_API_KEY
file_glob: true
file: "**/target/*.jar"
on:
repo: imduffy15/keycloak-extension-playground
tags: false
branch: master
4 changes: 2 additions & 2 deletions keycloak-playground-server/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,9 @@
<version>${project.version}</version>
</dependency>

<dependency>
<!-- <dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-testsuite-utils</artifactId>
</dependency>
</dependency> -->
</dependencies>
</project>
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package com.github.thomasdarimont.keycloak.server;
// package com.github.thomasdarimont.keycloak.server;

import org.keycloak.testsuite.KeycloakServer;
// import org.keycloak.testsuite.KeycloakServer;

public class KeycloakPlaygroundServer {
// public class KeycloakPlaygroundServer {

public static void main(String[] args) throws Throwable {
// public static void main(String[] args) throws Throwable {

System.out.println("Starting KeycloakPlaygroundServer");
KeycloakServer.main(args);
}
}
// System.out.println("Starting KeycloakPlaygroundServer");
// KeycloakServer.main(args);
// }
// }

0 comments on commit 69def8f

Please sign in to comment.