Documentation
¶
Index ¶
- func ApplyDeployment(ctx context.Context, cli client.Client, scheme *runtime.Scheme, ...) error
- func ApplyNetworkPolicy(ctx context.Context, c client.Client, scheme *runtime.Scheme, ...) error
- func ApplyResources(ctx context.Context, cli client.Client, scheme *runtime.Scheme, ...) error
- func CheckClusterRoleExists(ctx context.Context, cli client.Client, crb *unstructured.Unstructured) (bool, error)
- func FilterExcludeKinds(resMap *resmap.ResMap, kindsToExclude []string) (*resmap.ResMap, error)
- func GetOperatorNamespace() (string, error)
- func GetServiceName(instance *llamav1alpha1.LlamaStackDistribution) string
- func GetServicePort(instance *llamav1alpha1.LlamaStackDistribution) int32
- func HandleDisabledNetworkPolicy(ctx context.Context, c client.Client, ...) error
- func RenderManifest(fs filesys.FileSystem, manifestPath string, ...) (*resmap.ResMap, error)
- func RenderManifestWithContext(fs filesys.FileSystem, manifestsPath string, ...) (*resmap.ResMap, error)
- type ManifestContext
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyDeployment ¶
func ApplyDeployment(ctx context.Context, cli client.Client, scheme *runtime.Scheme, instance *llamav1alpha1.LlamaStackDistribution, deployment *appsv1.Deployment, logger logr.Logger) error
ApplyDeployment creates or updates the Deployment.
func ApplyNetworkPolicy ¶
func ApplyNetworkPolicy(ctx context.Context, c client.Client, scheme *runtime.Scheme, instance *llamav1alpha1.LlamaStackDistribution, networkPolicy *networkingv1.NetworkPolicy, log logr.Logger) error
ApplyNetworkPolicy creates or updates a NetworkPolicy.
func ApplyResources ¶
func ApplyResources( ctx context.Context, cli client.Client, scheme *runtime.Scheme, ownerInstance *llamav1alpha1.LlamaStackDistribution, resMap *resmap.ResMap, ) error
ApplyResources takes a Kustomize ResMap and applies the resources to the cluster.
func CheckClusterRoleExists ¶
func CheckClusterRoleExists(ctx context.Context, cli client.Client, crb *unstructured.Unstructured) (bool, error)
CheckClusterRoleExists checks if a RoleBinding should be skipped due to missing SCC ClusterRole.
func FilterExcludeKinds ¶
func GetOperatorNamespace ¶
func GetServiceName ¶
func GetServiceName(instance *llamav1alpha1.LlamaStackDistribution) string
func GetServicePort ¶
func GetServicePort(instance *llamav1alpha1.LlamaStackDistribution) int32
func HandleDisabledNetworkPolicy ¶
func HandleDisabledNetworkPolicy(ctx context.Context, c client.Client, networkPolicy *networkingv1.NetworkPolicy, log logr.Logger) error
HandleDisabledNetworkPolicy handles the deletion of a NetworkPolicy when the feature is disabled. It checks if the NetworkPolicy exists and deletes it if found.
func RenderManifest ¶
func RenderManifest( fs filesys.FileSystem, manifestPath string, ownerInstance *llamav1alpha1.LlamaStackDistribution, ) (*resmap.ResMap, error)
RenderManifest takes a manifest directory and transforms it through kustomization and plugins to produce final Kubernetes resources.
func RenderManifestWithContext ¶ added in v0.4.0
func RenderManifestWithContext( fs filesys.FileSystem, manifestsPath string, ownerInstance *llamav1alpha1.LlamaStackDistribution, manifestCtx *ManifestContext, ) (*resmap.ResMap, error)
RenderManifestWithContext renders manifests and enhances the Deployment with complex specs.