Documentation ¶
Index ¶
- func GetAppLabels(appName, category string) map[string]string
- func GetClusterAdminRoleRef() rbacv1.RoleRef
- func GetClusterRoleRef(name string) rbacv1.RoleRef
- func GetCoreRule() rbacv1.PolicyRule
- func GetCrdRule() rbacv1.PolicyRule
- func GetDefaultServiceAccountSubject(namespace string) rbacv1.Subject
- func GetIstioRule() rbacv1.PolicyRule
- func GetPodNamespaceEnvVar() v1.EnvVar
- func GetServiceAccountSubject(namespace, name string) rbacv1.Subject
- func MustCanonicalizeYaml(input string) string
- type ContainerSpec
- type PortSpec
- type ResourceBuilder
- func (b *ResourceBuilder) GetClusterRole() *rbacv1.ClusterRole
- func (b *ResourceBuilder) GetClusterRoleBinding() *rbacv1.ClusterRoleBinding
- func (b *ResourceBuilder) GetClusterRoleRef() rbacv1.RoleRef
- func (b *ResourceBuilder) GetConfigMap() *v1.ConfigMap
- func (b *ResourceBuilder) GetDeployment() *v1beta1.Deployment
- func (b *ResourceBuilder) GetDeploymentAppsv1() *appsv1.Deployment
- func (b *ResourceBuilder) GetNamespace() *v1.Namespace
- func (b *ResourceBuilder) GetRole() *rbacv1.Role
- func (b *ResourceBuilder) GetRoleBinding() *rbacv1.RoleBinding
- func (b *ResourceBuilder) GetSecret() *v1.Secret
- func (b *ResourceBuilder) GetService() *v1.Service
- func (b *ResourceBuilder) GetServiceAccount() *v1.ServiceAccount
- func (b *ResourceBuilder) GetServiceAccountSubject() rbacv1.Subject
- type ServiceSpec
- type TestManifest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAppLabels ¶
func GetClusterAdminRoleRef ¶
func GetClusterRoleRef ¶
func GetCoreRule ¶
func GetCoreRule() rbacv1.PolicyRule
func GetCrdRule ¶
func GetCrdRule() rbacv1.PolicyRule
func GetIstioRule ¶
func GetIstioRule() rbacv1.PolicyRule
func GetPodNamespaceEnvVar ¶
func MustCanonicalizeYaml ¶
Types ¶
type ContainerSpec ¶
type ContainerSpec struct { Image string PullPolicy v1.PullPolicy Name string Args []string EnvVars []v1.EnvVar }
func GetContainerSpec ¶
func GetContainerSpec(registry, name, tag string, envVars ...v1.EnvVar) ContainerSpec
func GetQuayContainerSpec ¶
func GetQuayContainerSpec(image, tag string, envVars ...v1.EnvVar) ContainerSpec
type ResourceBuilder ¶
type ResourceBuilder struct { Namespace string Name string Args []string Labels map[string]string Annotations map[string]string Rules []rbacv1.PolicyRule Data map[string]string Subjects []rbacv1.Subject RoleRef rbacv1.RoleRef Containers []ContainerSpec Service ServiceSpec SecretType v1.SecretType }
func (*ResourceBuilder) GetClusterRole ¶
func (b *ResourceBuilder) GetClusterRole() *rbacv1.ClusterRole
func (*ResourceBuilder) GetClusterRoleBinding ¶
func (b *ResourceBuilder) GetClusterRoleBinding() *rbacv1.ClusterRoleBinding
func (*ResourceBuilder) GetClusterRoleRef ¶
func (b *ResourceBuilder) GetClusterRoleRef() rbacv1.RoleRef
func (*ResourceBuilder) GetConfigMap ¶
func (b *ResourceBuilder) GetConfigMap() *v1.ConfigMap
func (*ResourceBuilder) GetDeployment ¶
func (b *ResourceBuilder) GetDeployment() *v1beta1.Deployment
func (*ResourceBuilder) GetDeploymentAppsv1 ¶ added in v0.9.11
func (b *ResourceBuilder) GetDeploymentAppsv1() *appsv1.Deployment
func (*ResourceBuilder) GetNamespace ¶
func (b *ResourceBuilder) GetNamespace() *v1.Namespace
func (*ResourceBuilder) GetRole ¶ added in v0.9.16
func (b *ResourceBuilder) GetRole() *rbacv1.Role
func (*ResourceBuilder) GetRoleBinding ¶ added in v0.9.16
func (b *ResourceBuilder) GetRoleBinding() *rbacv1.RoleBinding
func (*ResourceBuilder) GetSecret ¶
func (b *ResourceBuilder) GetSecret() *v1.Secret
func (*ResourceBuilder) GetService ¶
func (b *ResourceBuilder) GetService() *v1.Service
func (*ResourceBuilder) GetServiceAccount ¶
func (b *ResourceBuilder) GetServiceAccount() *v1.ServiceAccount
func (*ResourceBuilder) GetServiceAccountSubject ¶
func (b *ResourceBuilder) GetServiceAccountSubject() rbacv1.Subject
type ServiceSpec ¶
type ServiceSpec struct {
Ports []PortSpec
}
type TestManifest ¶
type TestManifest interface { ExpectDeployment(deployment *v1beta1.Deployment) ExpectDeploymentAppsV1(deployment *appsv1.Deployment) ExpectServiceAccount(serviceAccount *corev1.ServiceAccount) ExpectClusterRole(clusterRole *rbacv1.ClusterRole) ExpectClusterRoleBinding(clusterRoleBinding *rbacv1.ClusterRoleBinding) ExpectRole(role *rbacv1.Role) ExpectRoleBinding(roleBinding *rbacv1.RoleBinding) ExpectConfigMap(configMap *corev1.ConfigMap) ExpectConfigMapWithYamlData(configMap *corev1.ConfigMap) ExpectSecret(secret *corev1.Secret) ExpectService(service *corev1.Service) ExpectNamespace(namespace *corev1.Namespace) ExpectCrd(crd *extv1beta1.CustomResourceDefinition) ExpectCustomResource(gvk, namespace, name string) NumResources() int }
func NewTestManifest ¶
func NewTestManifest(relativePathToManifest string) TestManifest
func NewTestManifestWithResources ¶
func NewTestManifestWithResources(resources kuberesource.UnstructuredResources) TestManifest
Click to show internal directories.
Click to hide internal directories.