Remove --no-install
All checks were successful
Build / build (push) Successful in 2m24s

This commit is contained in:
Sebastiaan de Schaetzen 2025-02-10 13:19:56 +01:00
parent acc5bcdcfc
commit b9079e1e55
2 changed files with 4 additions and 7 deletions

View File

@ -16,4 +16,4 @@ COPY *.go ./
RUN go build -o /vivaplusdl RUN go build -o /vivaplusdl
RUN /vivaplusdl --install RUN /vivaplusdl --install
CMD ["/vivaplusdl", "--no-install"] CMD ["/vivaplusdl"]

View File

@ -12,18 +12,15 @@ import (
func main() { func main() {
var err error var err error
var noInstall = flag.Bool("no-install", false, "skip browser installation")
var onlyInstall = flag.Bool("install", false, "install the required browser and do nothing else") var onlyInstall = flag.Bool("install", false, "install the required browser and do nothing else")
flag.Parse() flag.Parse()
options := &playwright.RunOptions{ options := &playwright.RunOptions{
Browsers: []string{"firefox"}, Browsers: []string{"firefox"},
} }
if !*noInstall { err = playwright.Install(options)
err = playwright.Install(options) if err != nil {
if err != nil { log.Panicf("error installing playwright: %v", err)
log.Panicf("error installing playwright: %v", err)
}
} }
if *onlyInstall { if *onlyInstall {