Jelajahi Sumber

convert pka to seconds vice nsec

Matthew R Kasun 1 tahun lalu
induk
melakukan
f09dcda3a1
1 mengubah file dengan 1 tambahan dan 1 penghapusan
  1. 1 1
      controllers/migrate.go

+ 1 - 1
controllers/migrate.go

@@ -154,7 +154,7 @@ func convertLegacyHostNode(legacy models.LegacyNode) (models.Host, models.Node)
 	host.IsDocker = models.ParseBool(legacy.IsDocker)
 	host.IsK8S = models.ParseBool(legacy.IsK8S)
 	host.IsStatic = models.ParseBool(legacy.IsStatic)
-	host.PersistentKeepalive = time.Duration(legacy.PersistentKeepalive)
+	host.PersistentKeepalive = time.Duration(legacy.PersistentKeepalive) * time.Second
 	if host.PersistentKeepalive == 0 {
 		host.PersistentKeepalive = models.DefaultPersistentKeepAlive
 	}