server

package
v0.0.0-...-454d577 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 30, 2022 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AppVersion string = "1.1.0"
View Source
var Auth *htpasswd.File

Functions

func AgplHeaders

func AgplHeaders(c *fiber.Ctx) error

func AuthError401

func AuthError401(c *fiber.Ctx) error

func FileServer

func FileServer(c *fiber.Ctx) error

func FileServerLocked

func FileServerLocked(c *fiber.Ctx) error

func Forbidden403

func Forbidden403(c *fiber.Ctx) error

func HostinfoEndpoint

func HostinfoEndpoint(c *fiber.Ctx) error

func InitHtpasswdAuth

func InitHtpasswdAuth(htpath string) error

func RouteEndpoint

func RouteEndpoint(c *fiber.Ctx) error

func ServeError404

func ServeError404(c *fiber.Ctx) error

func ServerError500

func ServerError500(c *fiber.Ctx, err error) error

func ServerHeader

func ServerHeader(c *fiber.Ctx) error

Types

type Album

type Album struct {
	Cover string   `json:"cover"`
	Dir   string   `json:"dir"`
	Name  string   `json:"name"`
	Files []string `json:"files"`
}

type Hostinfo

type Hostinfo struct {
	Name      string  `json:"name"`
	Hosticon  string  `json:"hosticon"`
	Uuid      string  `json:"uuid"`
	Secured   bool    `json:"secured"`
	Size      int     `json:"size"`
	Root      string  `json:"root"`
	OriginURI string  `json:"originURI"`
	Albums    []Album `json:"albums"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL