Skip to content

Commit

Permalink
Issue #40: no special handling for no or single service
Browse files Browse the repository at this point in the history
With the upcoming new dashboard design (that also provides kiwix-readers along kiwix)
we agreed on not handling no-service or single service differently and always display
the dashboard
  • Loading branch information
rgaudin committed Jan 15, 2024
1 parent 79428df commit 9d39457
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions reverse-proxy/gen-caddyfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,13 +130,7 @@ def should_protect(self) -> bool:
redir /{{service.name}}* {scheme}://{{service.name}}.{$FQDN} permanent
{% endfor %}{% endif %}
{% if nb_services == 0 %}# no service at all (testing?)
respond "Hello world, you requested no service outch." 200
{% elif nb_services == 1 %}# single service, redirecting from home
redir / /{{ services.values() | map(attribute='name') | list | last }} permanent
{% else %}# home service has no endpoint
reverse_proxy home:80
{% endif %}
handle_errors {
respond "HTTP {http.error.status_code} Error ({http.error.message})"
Expand Down

0 comments on commit 9d39457

Please sign in to comment.