add config tempdir and default values
This commit is contained in:
parent
69b2d96c92
commit
da66c2fdf9
2 changed files with 9 additions and 0 deletions
|
@ -13,6 +13,7 @@ type Server struct {
|
||||||
|
|
||||||
type Worker struct {
|
type Worker struct {
|
||||||
ID string
|
ID string
|
||||||
|
TempDir string
|
||||||
Address string
|
Address string
|
||||||
Name string
|
Name string
|
||||||
FFmpegPath string
|
FFmpegPath string
|
||||||
|
|
8
main.go
8
main.go
|
@ -40,6 +40,14 @@ func main() {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if conf.Worker.FFmpegPath == "" {
|
||||||
|
conf.Worker.FFmpegPath = "ffmpeg"
|
||||||
|
}
|
||||||
|
|
||||||
|
if conf.Worker.TempDir == "" {
|
||||||
|
conf.Worker.TempDir = "/tmp"
|
||||||
|
}
|
||||||
|
|
||||||
if *isserver {
|
if *isserver {
|
||||||
slog.Info("Starting Server...")
|
slog.Info("Starting Server...")
|
||||||
server.Start(conf, templates, static, migrations)
|
server.Start(conf, templates, static, migrations)
|
||||||
|
|
Loading…
Add table
Reference in a new issue