oidc example auth
This commit is contained in:
20
templates/index.html
Normal file
20
templates/index.html
Normal file
@@ -0,0 +1,20 @@
|
||||
{% extends "base.html" %}
|
||||
{% block title %}Home – BoxDrop{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
{% if user %}
|
||||
<h1>Welcome back, {{ user.get('name') or user.get('email') }}! 👋</h1>
|
||||
<p>You are authenticated via Authentik.</p>
|
||||
<p><a class="btn" href="{{ url_for('dashboard') }}">Go to Dashboard</a></p>
|
||||
|
||||
<details style="margin-top:2rem">
|
||||
<summary>Raw token claims</summary>
|
||||
<pre style="background:#f4f4f4;padding:1rem;border-radius:4px;overflow:auto">{{ user | tojson(indent=2) }}</pre>
|
||||
</details>
|
||||
{% else %}
|
||||
<h1>BoxDrop</h1>
|
||||
<p>Please log in to continue.</p>
|
||||
<p><a class="btn" href="{{ url_for('login') }}">Log in with Authentik</a></p>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user