Add LDAP support

Not available upstream yet
This commit is contained in:
2026-05-19 16:31:30 +02:00
parent 1ac2cfcaab
commit 314bd6ab1a
3 changed files with 30 additions and 3 deletions

View File

@@ -27,7 +27,14 @@ storage:
<% @allowed_pubkeys.each do |pk| %>
- "<%= pk %>"
<% end %>
<% else %>
<% end %>
<% if @ldap['enabled'] %>
- type: "*"
expiration: "100 years"
ldap:
filter: "<%= @ldap['search_filter']%>"
<% end %>
<% if @allow_anonymous_uploads %>
- type: "image/*"
expiration: 1 month
- type: "video/*"
@@ -36,10 +43,19 @@ storage:
expiration: 1 week
<% end %>
<% if @ldap %>
ldap:
enabled: <%= @ldap['enabled'] %>
url: "<%= @ldap['url'] %>"
bindDN: "<%= @ldap['bind_dn'] %>"
password: "<%= @ldap['password'] %>"
searchDN: "<%= @ldap['search_dn'] %>"
<% end %>
upload:
enabled: true
requireAuth: <%= @allowed_pubkeys && !@allowed_pubkeys.empty? ? 'true' : 'false' %>
requirePubkeyInRule: <%= @allowed_pubkeys && !@allowed_pubkeys.empty? ? 'true' : 'false' %>
requireAuth: <%= !@allow_anonymous_uploads %>
requirePubkeyInRule: <%= !@allow_anonymous_uploads %>
maxSize: <%= @max_size %>
list: