From 62fe80d5c5dea8008f0f2bce80e1c4b42161d1a0 Mon Sep 17 00:00:00 2001 From: Jj! Date: Fri, 12 Oct 2018 10:29:47 -0500 Subject: [PATCH 1/7] [NOJIRA] updated doc update build for release --- backend/build.gradle | 6 +- .../src/main/resources/application.properties | 2 +- docs/CUSTOMIZATIONS.md | 12 +++- docs/DATABASE.md | 45 +++++++++++++++ docs/GETTINGSTARTED.md | 55 +++++++++++++++++++ docs/HOME.md | 6 ++ gradle.properties | 2 +- pac4j-module/build.gradle | 7 +-- 8 files changed, 124 insertions(+), 11 deletions(-) create mode 100644 docs/DATABASE.md create mode 100644 docs/GETTINGSTARTED.md create mode 100644 docs/HOME.md diff --git a/backend/build.gradle b/backend/build.gradle index 0710d1888..601be8bc4 100644 --- a/backend/build.gradle +++ b/backend/build.gradle @@ -44,7 +44,7 @@ bootWar { // into '/' into '/public' } - archiveName = "${baseName}.war" + archiveName = "${baseName}-${version}.war" } bootJar.dependsOn ':ui:npm_run_buildProd' @@ -61,7 +61,7 @@ bootJar { // into '/' into '/public' } - archiveName = "${baseName}.jar" + archiveName = "${baseName}-${version}.jar" } springBoot { @@ -241,5 +241,5 @@ docker { noCache true files tasks.bootJar.outputs files 'src/main/docker-files/loader.properties' - buildArgs(['JAR_FILE': 'shibui.jar']) + buildArgs(['JAR_FILE': "shibui-${version}.jar"]) } \ No newline at end of file diff --git a/backend/src/main/resources/application.properties b/backend/src/main/resources/application.properties index f97ab24a7..e91e8370d 100644 --- a/backend/src/main/resources/application.properties +++ b/backend/src/main/resources/application.properties @@ -35,7 +35,7 @@ spring.liquibase.enabled=false # Hibernate properties # for production never ever use create, create-drop. It's BEST to use validate -spring.jpa.hibernate.ddl-auto=create +spring.jpa.hibernate.ddl-auto=update spring.jpa.hibernate.naming.implicit-strategy=org.hibernate.boot.model.naming.ImplicitNamingStrategyJpaCompliantImpl spring.jpa.show-sql=false spring.jpa.properties.hibernate.format_sql=false diff --git a/docs/CUSTOMIZATIONS.md b/docs/CUSTOMIZATIONS.md index 0423fbce9..01662f668 100644 --- a/docs/CUSTOMIZATIONS.md +++ b/docs/CUSTOMIZATIONS.md @@ -45,4 +45,14 @@ If deploying a WAR, one would use the standard packaging for providing items to It is highly recommended that a WAR overlay be used to prevent changing the version fingerprint. Overlay methods exist for both Maven ([https://maven.apache.org/plugins/maven-war-plugin/overlays.html]) and -Gradle ([https://github.com/scalding/gradle-waroverlay-plugin]) projects. \ No newline at end of file +Gradle ([https://github.com/scalding/gradle-waroverlay-plugin]) projects. + +## Sample Customization + +For an example of a customization, refer to the `pac4j-module` in the project source. This module overrides the delivered +authentication method to provide a simple SAML authentication method. Along with code changes required, it also shows +how one would tie it together using a Docker image. + +## Use Cases and Strategies + +TBD \ No newline at end of file diff --git a/docs/DATABASE.md b/docs/DATABASE.md new file mode 100644 index 000000000..09c379ad1 --- /dev/null +++ b/docs/DATABASE.md @@ -0,0 +1,45 @@ +# Database configuration + +The Shibboleth UI application uses Spring Boot and Spring JPA for database configuration. Out of the box, it ships with +JDBC drivers for H2, MariaDB and Postgres. + +By default, it will use an in-memory H2 database. To change which database is used, one should make changes to the +`applications.properties` or `application.yml` file as appropriate. For further information, refer to the appropriate +JDBC driver documentation. + +```properties +# Database Credentials +spring.datasource.username=shibui +spring.datasource.password=shibui + +# Database Configuration H2 +spring.datasource.url=jdbc:h2:mem:shibui;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE +spring.datasource.platform=h2 +spring.datasource.driverClassName=org.h2.Driver +spring.jpa.database-platform=org.hibernate.dialect.H2Dialect +spring.h2.console.enabled=true + + +# Database Configuration PostgreSQL +#spring.datasource.url=jdbc:postgresql://localhost:5432/shibui +#spring.datasource.driverClassName=org.postgresql.Driver +#spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect + +#Maria/MySQL DB +#spring.datasource.url=jdbc:mariadb://localhost:3306/shibui +#spring.datasource.driverClassName=org.mariadb.jdbc.Driver +#spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MariaDBDialect + +# Liquibase properties +spring.liquibase.enabled=false +#spring.liquibase.change-log=classpath:edu/internet2/tier/shibboleth/admin/ui/database/masterchangelog.xml + +# Hibernate properties +# for production never ever use create, create-drop. It's BEST to use validate +spring.jpa.hibernate.ddl-auto=update +spring.jpa.hibernate.naming.implicit-strategy=org.hibernate.boot.model.naming.ImplicitNamingStrategyJpaCompliantImpl +spring.jpa.show-sql=false +spring.jpa.properties.hibernate.format_sql=false + +spring.jpa.hibernate.use-new-id-generator-mappings=true +``` \ No newline at end of file diff --git a/docs/GETTINGSTARTED.md b/docs/GETTINGSTARTED.md new file mode 100644 index 000000000..65da98a2c --- /dev/null +++ b/docs/GETTINGSTARTED.md @@ -0,0 +1,55 @@ +# Getting Started + +## Requirements + +* Java 8 (note that ONLY Java 8 is supported at this time) + +## Running + +There are currently 2 ways to run the application: + +1. As an executable +1. deployed in a Java Servlet 3.0 container + +Note that some features require encoded slashes in the URL. In tomcat (which is embedded in the war), this can be +allowed with: + +``` +-Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true +``` + +In Apache HTTPD, you'll need something like: + +``` + + AllowEncodedSlashes NoDecode + ServerName shibui.unicon.net + ProxyPass / http://localhost:8080/ nocanon + ProxyPassReverse / http://localhost:8080/ + +``` + +Note the `AllowEncodedSlashes NoDecode`. + +### Running as an executable + +`java -jar shibui.war` + +For complete information on overriding default configuration, see [https://docs.spring.io/spring-boot/docs/current/reference/html/boot-features-external-config.html]. + +### Deploying as a WAR + +The application can be deployed as a WAR file in a Java Servlet 3.0 container. Currently, the application must be run in the root context. + +To override default configuration, see [https://docs.spring.io/spring-boot/docs/current/reference/html/boot-features-external-config.html]. +The easiest way to do this in a servlet container is through the use of system properties + +## Authentication + +Currently, the application is wired with very simple authentication. A password for the user `user` +can be set with the `shibui.default-password` property. If none is set, a default password +will be generated and logged: + +``` +Using default security password: a3d9ab96-9c63-414f-b199-26fcf59e1ffa +``` \ No newline at end of file diff --git a/docs/HOME.md b/docs/HOME.md new file mode 100644 index 000000000..523c3fa38 --- /dev/null +++ b/docs/HOME.md @@ -0,0 +1,6 @@ +# Shibboleth UI + +* [DATABASE] +* [CUSTOMIZATIONS] +* [INTERNATIONALIZATION] +* [DATABASE] \ No newline at end of file diff --git a/gradle.properties b/gradle.properties index 678f56673..6dd86b202 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,6 +1,6 @@ name=shibui group=edu.internet2.tier.shibboleth.admin.ui -version=1.0.1-SNAPSHOT +version=1.0.4-SNAPSHOT shibboleth.version=3.4.0 opensaml.version=3.4.0 diff --git a/pac4j-module/build.gradle b/pac4j-module/build.gradle index 657add297..5133e4e48 100644 --- a/pac4j-module/build.gradle +++ b/pac4j-module/build.gradle @@ -11,9 +11,6 @@ sourceCompatibility = 1.8 targetCompatibility = 1.8 repositories { - maven () { - url 'https://oss.sonatype.org/content/groups/public' - } jcenter() maven { url 'https://build.shibboleth.net/nexus/content/groups/public' @@ -36,8 +33,8 @@ dependencies { compileOnly project(':backend') compile "org.pac4j:spring-security-pac4j:4.0.0" - compile "org.pac4j:pac4j-core:3.3.0-SNAPSHOT" - compile "org.pac4j:pac4j-saml:3.3.0-SNAPSHOT", { + compile "org.pac4j:pac4j-core:3.3.0" + compile "org.pac4j:pac4j-saml:3.3.0", { // opensaml libraries are provided exclude group: 'org.opensaml' } From 23819efce3248f6ab172d8915a41be474877f88a Mon Sep 17 00:00:00 2001 From: Jj! Date: Fri, 12 Oct 2018 11:08:28 -0500 Subject: [PATCH 2/7] [NOJIRA] update doc --- docs/CUSTOMIZATIONS.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/CUSTOMIZATIONS.md b/docs/CUSTOMIZATIONS.md index 01662f668..103137ef5 100644 --- a/docs/CUSTOMIZATIONS.md +++ b/docs/CUSTOMIZATIONS.md @@ -55,4 +55,6 @@ how one would tie it together using a Docker image. ## Use Cases and Strategies +Some ideas and strategies for customizing the application. + TBD \ No newline at end of file From bb6d4d6705c9a496463f58713994ba938bbb3c45 Mon Sep 17 00:00:00 2001 From: Jj! Date: Fri, 12 Oct 2018 11:24:52 -0500 Subject: [PATCH 3/7] [NOJIRA] update doc --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index a7f5b9994..07ce59ab0 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # shibui +For more information, see `docs` + ## Requirements * Java 8 (note that ONLY Java 8 is supported at this time) From 03ad2fd0f9764d33b82ab0a9434211970b444c6e Mon Sep 17 00:00:00 2001 From: Jj! Date: Fri, 12 Oct 2018 11:49:18 -0500 Subject: [PATCH 4/7] 1.4.0 Release --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 6dd86b202..cabc2301f 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,6 +1,6 @@ name=shibui group=edu.internet2.tier.shibboleth.admin.ui -version=1.0.4-SNAPSHOT +version=1.4.0 shibboleth.version=3.4.0 opensaml.version=3.4.0 From 9a2637a546274848130f13c90fb98566d89a71ba Mon Sep 17 00:00:00 2001 From: Jj! Date: Fri, 12 Oct 2018 12:21:13 -0500 Subject: [PATCH 5/7] 1.5.0 Development preparation --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index cabc2301f..60c4a518e 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,6 +1,6 @@ name=shibui group=edu.internet2.tier.shibboleth.admin.ui -version=1.4.0 +version=1.5.0-SNAPSHOT shibboleth.version=3.4.0 opensaml.version=3.4.0 From 862ff786f0792ae8769b7ebd550d38268a06aac4 Mon Sep 17 00:00:00 2001 From: Ryan Mathis Date: Fri, 12 Oct 2018 14:47:25 -0700 Subject: [PATCH 6/7] SHIBUI-928 Updating logo and footer --- .../main/resources/i18n/messages.properties | 7 +++ ui/src/app/app.component.html | 49 +++++++++++-------- ui/src/app/app.component.scss | 9 +++- 3 files changed, 44 insertions(+), 21 deletions(-) diff --git a/backend/src/main/resources/i18n/messages.properties b/backend/src/main/resources/i18n/messages.properties index ed9e61e67..72d6e706d 100644 --- a/backend/src/main/resources/i18n/messages.properties +++ b/backend/src/main/resources/i18n/messages.properties @@ -80,6 +80,13 @@ brand.footer.links-label-4=Mailing List brand.footer.links-desc-4=Shibboleth.net open-source community mailing list brand.footer.copyright=Copyright \u00A9 Internet2 +brand.unicon=Unicon +brand.unicon-logo=Unicon Logo +brand.i2=Internet 2 +brand.i2-logo=Internet 2 Logo +brand.in-partnership-with=In partnership with +brand.and=and + heading.shibboleth=Shibboleth label.metadata-source=Metadata Source diff --git a/ui/src/app/app.component.html b/ui/src/app/app.component.html index 4d6ba9564..cd56856e3 100644 --- a/ui/src/app/app.component.html +++ b/ui/src/app/app.component.html @@ -63,27 +63,36 @@
-
diff --git a/ui/src/app/app.component.scss b/ui/src/app/app.component.scss index 769799707..dbe420760 100644 --- a/ui/src/app/app.component.scss +++ b/ui/src/app/app.component.scss @@ -5,4 +5,11 @@ nav.navbar { .dropdown-menu { min-width: 12rem; } -} \ No newline at end of file +} + +.logo a { + img { + display: inline-block; + max-height: 60px; + } +} From 10c5b698c62fca076078f8e4572ec1ae1b31b76b Mon Sep 17 00:00:00 2001 From: Ryan Mathis Date: Fri, 12 Oct 2018 14:47:33 -0700 Subject: [PATCH 7/7] SHIBUI-928 Updating logo and footer --- ui/src/assets/logo_internet2.png | Bin 0 -> 1723 bytes ui/src/assets/logo_unicon.png | Bin 0 -> 2455 bytes 2 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 ui/src/assets/logo_internet2.png create mode 100644 ui/src/assets/logo_unicon.png diff --git a/ui/src/assets/logo_internet2.png b/ui/src/assets/logo_internet2.png new file mode 100644 index 0000000000000000000000000000000000000000..a2b280e5bd6e37820e63367c4029953f5a072f1e GIT binary patch literal 1723 zcmV;s21NOZP)#ZOwWsY{vYW$FF+30m2J~s(mvss-o9s<2i6QQBXXFLwg6C@B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