summaryrefslogtreecommitdiff
path: root/src/scm/webid-oidc/program.scm
diff options
context:
space:
mode:
Diffstat (limited to 'src/scm/webid-oidc/program.scm')
-rw-r--r--src/scm/webid-oidc/program.scm24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/scm/webid-oidc/program.scm b/src/scm/webid-oidc/program.scm
index 79f13cb..6b8ad29 100644
--- a/src/scm/webid-oidc/program.scm
+++ b/src/scm/webid-oidc/program.scm
@@ -24,6 +24,7 @@
#:use-module (webid-oidc server create)
#:use-module (webid-oidc jti)
#:use-module (webid-oidc offloading)
+ #:use-module (webid-oidc catalog)
#:use-module ((webid-oidc stubs) #:prefix stubs:)
#:use-module ((webid-oidc config) #:prefix cfg:)
#:use-module (ice-9 optargs)
@@ -55,8 +56,20 @@
(define date (date->string (time-utc->date (current-time))))
(define uri-string (if (uri? uri) (uri->string uri) uri))
(with-mutex logging-mutex
+ (when (getenv "XML_CATALOG_FILES")
+ (format (current-error-port) "~a: Warning: XML_CATALOG_FILES is set to ~s.\n"
+ date
+ (getenv "XML_CATALOG_FILES")))
(format (current-error-port) "~a: GET ~a ~s...\n"
date uri-string headers))
+ (set! uri (resolve-uri uri
+ #:http-get
+ (lambda* (uri . args)
+ (with-mutex logging-mutex
+ (format (current-error-port) "~a: Warning: loading XML catalog from the web, ~s.\n"
+ date
+ (uri->string uri)))
+ (apply http-get uri args))))
(receive (response response-body)
(in-another-thread
(http-get uri #:headers headers))
@@ -399,6 +412,17 @@ Options for the client service:"))
(format #t (G_ "
Environment variables:"))
(format #t (G_ "
+ XML_CATALOG_FILES: the server will fetch resources on the web. By
+ setting this environment variable to a space-separated list of
+ catalog URIs, the server will redirect these requests to another
+ server. Currently, it is not possible to load files from the
+ file system, because there is no way to specify the
+ content-type."))
+ (when (getenv "XML_CATALOG_FILES")
+ (format #t (G_ "the-environment-variable|
+ It is currently set to ~s.")
+ (getenv "XML_CATALOG_FILES")))
+ (format #t (G_ "
LANG: set the locale of the user interface (for the server commands,
the user is the system administrator)."))
(when (getenv "LANG")