ocp

package
v0.0.0-...-058426d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 23, 2024 License: Apache-2.0 Imports: 6 Imported by: 2

Documentation

Overview

Package ocp contains functions to obtain standard and recommended deployment artifacts for OpenShift. These artifacts can be used by automation tools that want to deploy Ceph-CSI.

Index

Constants

This section is empty.

Variables

View Source
var SecurityContextConstraintsDefaults = SecurityContextConstraintsValues{
	Namespace: "ceph-csi",
	Deployer:  "",
}

SecurityContextConstraintsDefaults can be used for generating deployment artifacts with details values.

Functions

func NewSecurityContextConstraints

func NewSecurityContextConstraints(values SecurityContextConstraintsValues) (*secv1.SecurityContextConstraints, error)

NewSecurityContextConstraints creates a new SecurityContextConstraints object by replacing variables in the template by the values set in the SecurityContextConstraintsValues.

The deployer parameter (when not an empty string) is used as a prefix for the name of the SCC and the linked ServiceAccounts.

func NewSecurityContextConstraintsYAML

func NewSecurityContextConstraintsYAML(values SecurityContextConstraintsValues) (string, error)

NewSecurityContextConstraintsYAML returns a YAML string where the variables in the template have been replaced by the values set in the SecurityContextConstraintsValues.

Types

type SecurityContextConstraintsValues

type SecurityContextConstraintsValues struct {
	// Namespace contains the OpenShift Namespace where the SCC will be
	// used.
	Namespace string
	// Deployer refers to the Operator that creates the SCC and
	// ServiceAccounts. This is an optional option.
	Deployer string
}

SecurityContextConstraintsValues contains values that need replacing in the template.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL