config

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AudioProfile added in v0.3.5

type AudioProfile struct {
	Bitrate int `mapstructure:"bitrate"` // in kilobytes
}

type Root

type Root struct {
	Debug   bool
	PProf   bool
	CfgFile string
}

func (Root) Init

func (Root) Init(cmd *cobra.Command) error

func (*Root) Set

func (s *Root) Set()

type Server

type Server struct {
	Cert   string
	Key    string
	Bind   string
	Static string
	Proxy  bool

	BaseDir  string            `yaml:"basedir,omitempty"`
	Streams  map[string]string `yaml:"streams"`
	Profiles string            `yaml:"profiles,omitempty"`

	Vod      VOD
	HlsProxy map[string]string
}

func (*Server) AbsPath added in v0.3.3

func (s *Server) AbsPath(elem ...string) string

func (Server) Init

func (Server) Init(cmd *cobra.Command) error

func (*Server) Set

func (s *Server) Set()

type VOD added in v0.3.5

type VOD struct {
	MediaDir       string                  `mapstructure:"media-dir"`
	TranscodeDir   string                  `mapstructure:"transcode-dir"`
	VideoProfiles  map[string]VideoProfile `mapstructure:"video-profiles"`
	VideoKeyframes bool                    `mapstructure:"video-keyframes"`
	AudioProfile   AudioProfile            `mapstructure:"audio-profile"`
	Cache          bool                    `mapstructure:"cache"`
	CacheDir       string                  `mapstructure:"cache-dir"`
	FFmpegBinary   string                  `mapstructure:"ffmpeg-binary"`
	FFprobeBinary  string                  `mapstructure:"ffprobe-binary"`
}

type VideoProfile added in v0.3.5

type VideoProfile struct {
	Width   int `mapstructure:"width"`
	Height  int `mapstructure:"height"`
	Bitrate int `mapstructure:"bitrate"` // in kilobytes
}

Jump to

Keyboard shortcuts

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