config

package
v0.0.0-...-ad8d7c7 Latest Latest
Warning

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

Go to latest
Published: May 8, 2023 License: AGPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Input struct {
		Sources []InputSource `fig:"sources"`
	}

	Output struct {
		Sources []OutputSource `fig:"sources"`
	}

	Service struct {
		Type string `fig:"type" validate:"required"`

		Endpoint     string `fig:"endpoint"`
		ClientID     string `fig:"client_id"`
		ClientSecret string `fig:"client_secret"`
	}

	Orchestrator struct {
		Type string `fig:"type" validate:"required"`

		Endpoint     string `fig:"endpoint"`
		Key          string `fig:"key"`
		WHEPEndpoint string `fig:"whep_endpoint"`

		Address    string `fig:"address"`
		RegionCode string `fig:"region_code"`
	}

	Control struct {
		Service      string `fig:"service"`
		Orchestrator string `fig:"orchestrator"`
		LogLevel     string `fig:"log_level" default:"info"`

		Address        string `fig:"http_address"`
		HTTPServerType string `fig:"http_server_type"`
		HTTPSHostname  string `fig:"https_hostname"`
		HTTPSCert      string `fig:"https_cert"`
		HTTPSKey       string `fig:"https_key"`

		SaveVideo bool `fig:"save_video"`
	}
}

func Load

func Load() (Config, error)

type InputSource

type InputSource struct {
	Type string `fig:"type" validate:"required"`

	Address string `fig:"address" validate:"required"`

	// fs, whip
	VideoFile string `fig:"video_file"`
	AudioFile string `fig:"audio_file"`

	// janus
	ChannelID int `fig:"channel_id"`
}

type OutputSource

type OutputSource struct {
	Type string `fig:"type" validate:"required"`

	Address string `fig:"address" validate:"required"`

	Server        string `fig:"server"`
	HTTPS         bool
	HTTPSHostname string `fig:"https_hostname"`
	HTTPSCert     string `fig:"https_cert"`
	HTTPSKey      string `fig:"https_key"`
}

Jump to

Keyboard shortcuts

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