mirror of
https://github.com/rclone/rclone.git
synced 2025-01-22 13:52:01 +08:00
parent
dbb21165d4
commit
7c7606a6cf
11
cmd/cmd.go
11
cmd/cmd.go
|
@ -429,11 +429,12 @@ func initConfig() {
|
|||
fs.Fatalf(nil, "Failed to start remote control: %v", err)
|
||||
}
|
||||
|
||||
// Start the metrics server if configured
|
||||
_, err = rcserver.MetricsStart(ctx, &rc.Opt)
|
||||
if err != nil {
|
||||
fs.Fatalf(nil, "Failed to start metrics server: %v", err)
|
||||
|
||||
// Start the metrics server if configured and not running the "rc" command
|
||||
if os.Args[1] != "rc" {
|
||||
_, err = rcserver.MetricsStart(ctx, &rc.Opt)
|
||||
if err != nil {
|
||||
fs.Fatalf(nil, "Failed to start metrics server: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
// Setup CPU profiling if desired
|
||||
|
|
Loading…
Reference in New Issue
Block a user