Documentation
¶
Index ¶
- Constants
- func APIsToWatch() ([]ctrlclient.Object, error)
- func AddToScheme(scheme *runtime.Scheme) error
- func GeneratePassword() (string, error)
- func NewClient(ctx context.Context, c ctrlclient.Client, logger logr.Logger, ...) (transport.Transport, error)
- func NewServer(ctx context.Context, c ctrlclient.Client, logger logr.Logger, ...) (transport.Transport, error)
Constants ¶
const ( CredentialsTypePSK transport.CredentialsType = "PSK" CredentialsTypeSSL transport.CredentialsType = "SSL" )
const ( TransportTypeStunnel transport.Type = "stunnel" Container = "stunnel" )
Variables ¶
This section is empty.
Functions ¶
func APIsToWatch ¶
func APIsToWatch() ([]ctrlclient.Object, error)
APIsToWatch give a list of APIs to watch if using this package to deploy the transport
func AddToScheme ¶
AddToScheme should be used as soon as scheme is created to add core objects for encoding/decoding
func GeneratePassword ¶
GeneratePassword can be used to generate random character string of 32 bytes
func NewClient ¶
func NewClient(ctx context.Context, c ctrlclient.Client, logger logr.Logger, namespacedName types.NamespacedName, hostname string, connectPort int32, options *transport.Options) (transport.Transport, error)
NewClient creates the stunnel client object, deploys the resource on the cluster and then generates the necessary containers and volumes for transport to consume.
Before passing the client c make sure to call AddToScheme() if core types are not already registered In order to generate the right RBAC, add the following lines to the Reconcile function annotations. +kubebuilder:rbac:groups=core,resources=configmaps,secrets,verbs=get;list;watch;create;update;patch;delete
func NewServer ¶
func NewServer(ctx context.Context, c ctrlclient.Client, logger logr.Logger, namespacedName types.NamespacedName, e endpoint.Endpoint, options *transport.Options) (transport.Transport, error)
NewServer creates the stunnel server object, deploys the resource on the cluster and then generates the necessary containers and volumes for transport to consume.
Before passing the client c make sure to call AddToScheme() if core types are not already registered In order to generate the right RBAC, add the following lines to the Reconcile function annotations. +kubebuilder:rbac:groups=core,resources=configmaps;secrets,verbs=get;list;watch;create;update;patch;delete
Types ¶
This section is empty.