Skip to content

Repository files navigation

dashboard

Caddy-based file server serving static file with home-page generated on startup

Configuration

Configuration is done via a YAML file describing the contents that should be exposed.

VariableUsage
metadataA dict containing hompage-level metadata
metadata.nameHotspot name
metadata.fqdnDomain name of the hotspot. Used to build links
packagesA list of package dicts describing each content package
package.titleMain name of content
package.kindKind of package, to adjust display and filters
package.descriptionShort description of the content
package.languagesList of ISO-639-3 language code the content relates to
package.tagsList of Tag strings helping users guess what to expect from content
package.iconBase64 encoded 48x48px PNG image
package.urlURL to access the content on the hotspot. Accepts some variables
package.download.urlURL to download the content from (for hotspot users)
package.download.sizeSize of the download file to download. Informative only

Main goal of this tool being linking to content, package.url accepts different helpers which are rewritten automatically:

  • {fqdn} is replaced by the content of metadata.fqdn.
  • {service-fqdn} is replaced by the service's subdomain. Ex: {kiwix-fqdn} may become kiwix.myname.hotspot.
  • URLs not starting with a scheme (urllib.parse.urlparse) will be prefixed with //.
  • // is the only scheme-less prefix allowed.
  • Use http:// or https:// to enforce protocol.
  • You can use external links (at your own risk of it not working)
  • Other protocols alike.

Sample

---
metadata:
name: My Hotspotfqdn: renaud.Hotspotpackages:
kind: zimtitle: ArchWikidescription: Arch Linux documentationlanguages:
- engtags:
- archlinuxurl: //{kiwix-fqdn}/archlinux_en_all_maxi_2022-04download:
url: //{zimdl-fqdn}/archlinux_en_all_maxi_2022-04.zimsize: 32M

In addition, the DEBUG environ can be set to enable Caddy debug output.

About

Kiwix Hotspot dashboard (homepage, configuration, ...)

Resources

Stars

4 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages