wip: migrate to mono-repo. SPN has already been moved to spn/

This commit is contained in:
Patrick Pacher
2024-03-15 11:55:13 +01:00
parent b30fd00ccf
commit 8579430db9
577 changed files with 35981 additions and 818 deletions

30
spn/conf/mode.go Normal file
View File

@@ -0,0 +1,30 @@
package conf
import (
"github.com/tevino/abool"
)
var (
publicHub = abool.New()
client = abool.New()
)
// PublicHub returns whether this is a public Hub.
func PublicHub() bool {
return publicHub.IsSet()
}
// EnablePublicHub enables the public hub mode.
func EnablePublicHub(enable bool) {
publicHub.SetTo(enable)
}
// Client returns whether this is a client.
func Client() bool {
return client.IsSet()
}
// EnableClient enables the client mode.
func EnableClient(enable bool) {
client.SetTo(enable)
}