github.com/spotahome/redis-operator@v1.2.4/api/redisfailover/v1/bootstrapping.go (about) 1 package v1 2 3 // Bootstrapping returns true when a BootstrapNode is provided to the RedisFailover spec. Otherwise, it returns false. 4 func (r *RedisFailover) Bootstrapping() bool { 5 return r.Spec.BootstrapNode != nil 6 } 7 8 // SentinelsAllowed returns true if not Bootstrapping orif BootstrapNode settings allow sentinels to exist 9 func (r *RedisFailover) SentinelsAllowed() bool { 10 bootstrapping := r.Bootstrapping() 11 return !bootstrapping || (bootstrapping && r.Spec.BootstrapNode.AllowSentinels) 12 }