feat: redirect handler

Signed-off-by: Wouter Termont <woutermont@gmail.com>
This commit is contained in:
Wouter Termont
2022-04-05 21:33:09 +02:00
parent 5e6c42e1f8
commit a9b160f58c
5 changed files with 145 additions and 0 deletions

View File

@@ -1,6 +1,7 @@
{
"@context": "https://linkedsoftwaredependencies.org/bundles/npm/@solid/community-server/^3.0.0/components/context.jsonld",
"import": [
"files-scs:config/http/handler/handlers/redirect.json",
"files-scs:config/http/handler/handlers/oidc.json"
],
"@graph": [

View File

@@ -0,0 +1,17 @@
{
"@context": "https://linkedsoftwaredependencies.org/bundles/npm/@solid/community-server/^3.0.0/components/context.jsonld",
"@graph": [
{
"comment": "Example handler to configure redirect patterns. Add to urn:solid-server:default:HttpHandler",
"@id": "urn:solid-server:default:RedirectHandler",
"@type": "RedirectingHttpHandler",
"redirects": [
{
"RedirectingHttpHandler:_redirects_key": "/from/(.*)",
"RedirectingHttpHandler:_redirects_value": "/to/$1"
}
],
"statusCode": "303"
}
]
}