Documentation ¶
Overview ¶
Package app manages main application server.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type App ¶
type App struct { Config *Config Library *media.Library Watcher *fsnotify.Watcher Templates *template.Template Feed []byte Tor *tor Listener net.Listener Router *mux.Router }
App represents main application.
type Config ¶
type Config struct { Library []*PathConfig `json:"library"` Server *ServerConfig `json:"server"` Feed *FeedConfig `json:"feed"` Tor *TorConfig `json:"tor,omitempty"` }
Config settings for main App.
func DefaultConfig ¶
func DefaultConfig() *Config
DefaultConfig returns Config initialized with default values.
type FeedConfig ¶
type FeedConfig struct { ExternalURL string `json:"external_url"` Title string `json:"title"` Link string `json:"link"` Description string `json:"description"` Author struct { Name string `json:"name"` Email string `json:"email"` } `json:"author"` Copyright string `json:"copyright"` }
FeedConfig settings for App Feed.
type PathConfig ¶ added in v0.1.0
PathConfig settings for media library path.
type ServerConfig ¶
ServerConfig settings for App Server.
type TorConfig ¶ added in v0.1.0
type TorConfig struct { Enable bool `json:"enable"` Controller *TorControllerConfig `json:"controller"` }
TorConfig stores tor configuration.
type TorControllerConfig ¶ added in v0.1.0
type TorControllerConfig struct { Host string `json:"host"` Port int `json:"port"` Password string `json:"password,omitempty"` }
TorControllerConfig stores tor controller configuration.
Click to show internal directories.
Click to hide internal directories.