mirror of
https://github.com/gotenberg/gotenberg.git
synced 2026-08-08 16:42:15 +01:00
21 lines
506 B
Go
21 lines
506 B
Go
package main
|
|
|
|
import (
|
|
"github.com/thecodingmachine/gotenberg/internal/pkg/chrome"
|
|
"github.com/thecodingmachine/gotenberg/internal/pkg/conf"
|
|
"github.com/thecodingmachine/gotenberg/internal/pkg/xlog"
|
|
)
|
|
|
|
func main() {
|
|
const op string = "main"
|
|
config, err := conf.FromEnv()
|
|
systemLogger := xlog.New(config.LogLevel(), "system")
|
|
if err != nil {
|
|
systemLogger.FatalOp(op, err)
|
|
}
|
|
// start Google Chrome headless.
|
|
if err := chrome.Start(systemLogger); err != nil {
|
|
systemLogger.FatalOp(op, err)
|
|
}
|
|
}
|