[java-idp-jetty-base] 01/02: IDP-2334 Determine sensible defaults for the server's root page.
Rod Widdowson
rdw at steadingsoftware.com
Fri Oct 11 13:14:32 UTC 2024
This is an automated email from the git hooks/post-receive script.
rdw pushed a commit to branch dev/IDP-2297
in repository java-idp-jetty-base.
View the commit online:
http://git.shibboleth.net/view/?p=java-idp-jetty-base.git;a=commit;h=e9255e3d745a64a41194e02f0aac47e198c61aab
commit e9255e3d745a64a41194e02f0aac47e198c61aab
Author: Rod Widdowson <rdw at steadingsoftware.com>
AuthorDate: Fri Oct 11 10:56:11 2024 +0100
IDP-2334 Determine sensible defaults for the server's root page.
https://shibboleth.atlassian.net/browse/IDP-2334
* Set jetty.server.default.showContexts to false
* Create an empty index.html in static
For ease this checking also stops copying the p12 file. Creating that file will be addede in the
next checkin.
---
.../java/net/shibboleth/idp/plugin/jettybase/JettyBaseModule.java | 3 +--
.../net/shibboleth/idp/plugin/jettybase/module.properties | 4 ++--
.../net/shibboleth/idp/plugin/jettybase/module/start.d/idp.ini | 2 ++
.../net/shibboleth/idp/plugin/jettybase/module/static/index.html | 8 ++++++++
4 files changed, 13 insertions(+), 4 deletions(-)
diff --git a/jetty-base-impl/src/main/java/net/shibboleth/idp/plugin/jettybase/JettyBaseModule.java b/jetty-base-impl/src/main/java/net/shibboleth/idp/plugin/jettybase/JettyBaseModule.java
index d71b5e9..ff0ba34 100644
--- a/jetty-base-impl/src/main/java/net/shibboleth/idp/plugin/jettybase/JettyBaseModule.java
+++ b/jetty-base-impl/src/main/java/net/shibboleth/idp/plugin/jettybase/JettyBaseModule.java
@@ -50,9 +50,8 @@ public class JettyBaseModule extends PluginIdPModule {
final Map<ModuleResource, ResourceResult> result = super.enable(moduleContext);
final Path idpHome = Path.of(moduleContext.getInstallLocation());
final Path jettyBase = idpHome.resolve("jetty-base");
- log.debug("Creating directories (if needed): '{}' '{}'\n", idpHome.resolve("static"), jettyBase.resolve("tmp"));
+ log.debug("Creating directories (if needed): '{}' '{}'\n", jettyBase.resolve("tmp"));
try {
- Files.createDirectories(idpHome.resolve("static"));
Files.createDirectories(jettyBase.resolve("tmp"));
} catch (final IOException e) {
log.error("Create Directory failed", e);
diff --git a/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module.properties b/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module.properties
index c96f36e..aa7b4b2 100644
--- a/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module.properties
+++ b/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module.properties
@@ -24,8 +24,8 @@ jetty.base.module.4.dest = jetty-base/webapps/idp.xml
jetty.base.module.5.src = /net/shibboleth/idp/plugin/jettybase/module/webapps/static.xml
jetty.base.module.5.dest = jetty-base/webapps/static.xml
-jetty.base.module.6.src = /net/shibboleth/idp/plugin/jettybase/module/credentials/idp-userfacing.p12
-jetty.base.module.6.dest = credentials/idp-userfacing.p12
+jetty.base.module.6.src = /net/shibboleth/idp/plugin/jettybase/module/static/index.html
+jetty.base.module.6.dest = jetty-base/static/index.html
# For legacy reasons we separate Windows and non windows start.d
diff --git a/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module/start.d/idp.ini b/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module/start.d/idp.ini
index 242e857..ba0a917 100644
--- a/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module/start.d/idp.ini
+++ b/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module/start.d/idp.ini
@@ -38,3 +38,5 @@ etc/jetty-requestlog.xml
jetty.http.host=127.0.0.1
## jetty default is 8080
## jetty.http.port=80
+
+jetty.server.default.showContexts=false
diff --git a/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module/static/index.html b/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module/static/index.html
new file mode 100644
index 0000000..04b3dc1
--- /dev/null
+++ b/jetty-base-impl/src/main/resources/net/shibboleth/idp/plugin/jettybase/module/static/index.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+
+<html>
+
+<head>
+<title>Add your stuff here</title>
+</head>
+</html>
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list