Skip to content

Commit

Permalink
fix: startup order
Browse files Browse the repository at this point in the history
  • Loading branch information
natesales committed Jan 15, 2025
1 parent 3be86f7 commit fe72e89
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions cmd/shim/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,15 +71,15 @@ func main() {
log.Fatalf("requesting TLS certificate: %s", err)
}

log.Printf("Starting HTTPS server on vsock:%d", opts.VSockListenPort)
go log.Fatal(srv.Listen())

log.Printf("Running command: %v\n", args[1:])
go func() {
log.Printf("Running command: %v\n", args[1:])
cmd := exec.Command(args[1], args[2:]...)
cmd.Stdin = os.Stdin
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
log.Fatal(cmd.Run())
}()

// Run command
cmd := exec.Command(args[1], args[2:]...)
cmd.Stdin = os.Stdin
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
log.Fatal(cmd.Run())
log.Printf("Starting HTTPS server on vsock:%d", opts.VSockListenPort)
log.Fatal(srv.Listen())
}

0 comments on commit fe72e89

Please sign in to comment.