diff --git a/lib/Lufi/Controller/Auth.pm b/lib/Lufi/Controller/Auth.pm index 7405694..9913cad 100644 --- a/lib/Lufi/Controller/Auth.pm +++ b/lib/Lufi/Controller/Auth.pm @@ -51,7 +51,12 @@ sub log_out { $c->logout; } } - $c->render(template => 'logout'); + + if ($c->config('logout_custom')) { + return $c->redirect_to($c->config('logout_custom')); + } else { + $c->render(template => 'logout'); + } } 1; diff --git a/lufi.conf.template b/lufi.conf.template index f89d376..778391d 100644 --- a/lufi.conf.template +++ b/lufi.conf.template @@ -101,6 +101,9 @@ # optional, no domains allowed by default #allowed_domains => ['http://1.example.com', 'http://2.example.com'], + # String of the URL to be redirected to when accessing /logout + #logout_custom => 'https://sso.example.com/logout?redirect_uri=https%3A%2F%2Ffiat-tux.fr', + # Define a path to the upload directory, where the uploaded files will be stored # You can define it relative to lufi directory or set an absolute path # Remember that it has to be in a directory writable by Lufi user