summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2024-10-26 10:17:55 -0500
committerJeff Carr <[email protected]>2024-10-26 10:17:55 -0500
commit636068c5b790564915f59960c1a6ceebe877c978 (patch)
treeae35917124491a7893cca0646e157f45cbfc6fc8
parent0c716b02d7588d514512c19486bc4d8a0473c840 (diff)
export these func()
Signed-off-by: Jeff Carr <[email protected]>
-rw-r--r--addDroplet.go2
-rw-r--r--validate.go8
2 files changed, 5 insertions, 5 deletions
diff --git a/addDroplet.go b/addDroplet.go
index 092040a..14beff4 100644
--- a/addDroplet.go
+++ b/addDroplet.go
@@ -360,7 +360,7 @@ func updateDisk(cluster *pb.Cluster, d *pb.Droplet, domcfg *libvirtxml.Domain) (
continue
}
- e, err := insertFilename(cluster, d, filename)
+ e, err := InsertFilename(cluster, d, filename)
if err != nil {
return alle, err
}
diff --git a/validate.go b/validate.go
index 979d201..bfac46a 100644
--- a/validate.go
+++ b/validate.go
@@ -72,7 +72,7 @@ func lookupFilename(cluster *pb.Cluster, filename string) *pb.Droplet {
return nil
}
-func insertFilename(cluster *pb.Cluster, d *pb.Droplet, filename string) (*pb.Event, error) {
+func InsertFilename(cluster *pb.Cluster, d *pb.Droplet, filename string) (*pb.Event, error) {
dupd := lookupFilename(cluster, filename)
if dupd != nil {
log.Info("file", filename, "already on droplet", dupd.Hostname)
@@ -105,7 +105,7 @@ func insertFilename(cluster *pb.Cluster, d *pb.Droplet, filename string) (*pb.Ev
return e, nil
}
-func checkUniqueFilenames(cluster *pb.Cluster) bool {
+func CheckUniqueFilenames(cluster *pb.Cluster) bool {
var ok bool = true
var disks map[string]string
disks = make(map[string]string)
@@ -135,7 +135,7 @@ func checkUniqueFilenames(cluster *pb.Cluster) bool {
return ok
}
-func checkDiskFilenames(cluster *pb.Cluster) []*pb.Event {
+func CheckDiskFilenames(cluster *pb.Cluster) []*pb.Event {
var alle []*pb.Event
for _, d := range cluster.Droplets {
@@ -167,7 +167,7 @@ func checkDiskFilenames(cluster *pb.Cluster) []*pb.Event {
return alle
}
-func checkDroplets(cluster *pb.Cluster, dump bool) bool {
+func CheckDroplets(cluster *pb.Cluster, dump bool) bool {
// uuid map to check for duplicates
var umap map[string]string
umap = make(map[string]string)