Skip to content

Commit

Permalink
fixes CRD (#322)
Browse files Browse the repository at this point in the history
adds preserveUnknownFields to each deleted CRD
#321
  • Loading branch information
f41gh7 authored Sep 2, 2021
1 parent 193d502 commit 8f79fdd
Show file tree
Hide file tree
Showing 15 changed files with 160 additions and 881 deletions.
164 changes: 40 additions & 124 deletions Makefile

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions config/crd/bases/operator.victoriametrics.com_vmagents.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,7 @@ spec:
affinity:
description: Affinity If specified, the pod's scheduling constraints.
type: object
x-kubernetes-preserve-unknown-fields: true
arbitraryFSAccessThroughSMs:
description: ArbitraryFSAccessThroughSMs configures whether configuration
based on a service scrape can access arbitrary files on the file
Expand Down Expand Up @@ -323,6 +324,7 @@ spec:
required:
- name
type: object
x-kubernetes-preserve-unknown-fields: true
type: array
host_aliases:
description: HostAliases provides mapping between ip and hostnames,
Expand Down Expand Up @@ -486,6 +488,7 @@ spec:
livenessProbe:
description: LivenessProbe that will be added CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
logFormat:
description: LogFormat for VMAgent to be configured with.
enum:
Expand Down Expand Up @@ -852,6 +855,7 @@ spec:
readinessProbe:
description: ReadinessProbe that will be added CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
relabelConfig:
description: RelabelConfig ConfigMap with global relabel config -remoteWrite.relabelConfig
This relabeling is applied to all the collected metrics before sending
Expand Down Expand Up @@ -1380,6 +1384,7 @@ spec:
description: SecurityContext holds pod-level security attributes and
common container settings. This defaults to the default PodSecurityContext.
type: object
x-kubernetes-preserve-unknown-fields: true
serviceAccountName:
description: ServiceAccountName is the name of the ServiceAccount
to use to run the VMAgent Pods.
Expand Down Expand Up @@ -1511,6 +1516,7 @@ spec:
description: 'ServiceSpec describes the attributes that a user
creates on a service. More info: https://kubernetes.io/docs/concepts/services-networking/service/'
type: object
x-kubernetes-preserve-unknown-fields: true
required:
- spec
type: object
Expand All @@ -1522,6 +1528,7 @@ spec:
startupProbe:
description: StartupProbe that will be added to CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
staticScrapeNamespaceSelector:
description: StaticScrapeNamespaceSelector defines Namespaces to be
selected for VMStaticScrape discovery. If nil, only check own namespace.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2518,7 +2518,6 @@ spec:
description: Child routes.
items:
x-kubernetes-preserve-unknown-fields: true
type: object
type: array
required:
- receiver
Expand Down
147 changes: 7 additions & 140 deletions config/crd/bases/operator.victoriametrics.com_vmalertmanagers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ spec:
affinity:
description: Affinity If specified, the pod's scheduling constraints.
type: object
x-kubernetes-preserve-unknown-fields: true
clusterAdvertiseAddress:
description: 'ClusterAdvertiseAddress is the explicit address to advertise
in cluster. Needs to be provided for non RFC1918 [1] (public) addresses.
Expand Down Expand Up @@ -221,6 +222,7 @@ spec:
required:
- name
type: object
x-kubernetes-preserve-unknown-fields: true
type: array
hostNetwork:
description: HostNetwork controls whether the pod may use the node
Expand Down Expand Up @@ -281,6 +283,7 @@ spec:
livenessProbe:
description: LivenessProbe that will be added CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
logFormat:
description: LogFormat for VMAlertmanager to be configured with.
type: string
Expand Down Expand Up @@ -364,6 +367,7 @@ spec:
readinessProbe:
description: ReadinessProbe that will be added CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
replicaCount:
description: ReplicaCount Size is the expected size of the alertmanager
cluster. The controller will eventually make the size of the running
Expand Down Expand Up @@ -427,147 +431,8 @@ spec:
securityContext:
description: SecurityContext holds pod-level security attributes and
common container settings. This defaults to the default PodSecurityContext.
properties:
fsGroup:
description: "A special supplemental group that applies to all
containers in a pod. Some volume types allow the Kubelet to
change the ownership of that volume to be owned by the pod:
\n 1. The owning GID will be the FSGroup 2. The setgid bit is
set (new files created in the volume will be owned by FSGroup)
3. The permission bits are OR'd with rw-rw---- \n If unset,
the Kubelet will not modify the ownership and permissions of
any volume."
format: int64
type: integer
fsGroupChangePolicy:
description: 'fsGroupChangePolicy defines behavior of changing
ownership and permission of the volume before being exposed
inside Pod. This field will only apply to volume types which
support fsGroup based ownership(and permissions). It will have
no effect on ephemeral volume types such as: secret, configmaps
and emptydir. Valid values are "OnRootMismatch" and "Always".
If not specified, "Always" is used.'
type: string
runAsGroup:
description: The GID to run the entrypoint of the container process.
Uses runtime default if unset. May also be set in SecurityContext. If
set in both SecurityContext and PodSecurityContext, the value
specified in SecurityContext takes precedence for that container.
format: int64
type: integer
runAsNonRoot:
description: Indicates that the container must run as a non-root
user. If true, the Kubelet will validate the image at runtime
to ensure that it does not run as UID 0 (root) and fail to start
the container if it does. If unset or false, no such validation
will be performed. May also be set in SecurityContext. If set
in both SecurityContext and PodSecurityContext, the value specified
in SecurityContext takes precedence.
type: boolean
runAsUser:
description: The UID to run the entrypoint of the container process.
Defaults to user specified in image metadata if unspecified.
May also be set in SecurityContext. If set in both SecurityContext
and PodSecurityContext, the value specified in SecurityContext
takes precedence for that container.
format: int64
type: integer
seLinuxOptions:
description: The SELinux context to be applied to all containers.
If unspecified, the container runtime will allocate a random
SELinux context for each container. May also be set in SecurityContext. If
set in both SecurityContext and PodSecurityContext, the value
specified in SecurityContext takes precedence for that container.
properties:
level:
description: Level is SELinux level label that applies to
the container.
type: string
role:
description: Role is a SELinux role label that applies to
the container.
type: string
type:
description: Type is a SELinux type label that applies to
the container.
type: string
user:
description: User is a SELinux user label that applies to
the container.
type: string
type: object
seccompProfile:
description: The seccomp options to use by the containers in this
pod.
properties:
localhostProfile:
description: localhostProfile indicates a profile defined
in a file on the node should be used. The profile must be
preconfigured on the node to work. Must be a descending
path, relative to the kubelet's configured seccomp profile
location. Must only be set if type is "Localhost".
type: string
type:
description: "type indicates which kind of seccomp profile
will be applied. Valid options are: \n Localhost - a profile
defined in a file on the node should be used. RuntimeDefault
- the container runtime default profile should be used.
Unconfined - no profile should be applied."
type: string
required:
- type
type: object
supplementalGroups:
description: A list of groups applied to the first process run
in each container, in addition to the container's primary GID. If
unspecified, no groups will be added to any container.
items:
format: int64
type: integer
type: array
sysctls:
description: Sysctls hold a list of namespaced sysctls used for
the pod. Pods with unsupported sysctls (by the container runtime)
might fail to launch.
items:
description: Sysctl defines a kernel parameter to be set
properties:
name:
description: Name of a property to set
type: string
value:
description: Value of a property to set
type: string
required:
- name
- value
type: object
type: array
windowsOptions:
description: The Windows specific settings applied to all containers.
If unspecified, the options within a container's SecurityContext
will be used. If set in both SecurityContext and PodSecurityContext,
the value specified in SecurityContext takes precedence.
properties:
gmsaCredentialSpec:
description: GMSACredentialSpec is where the GMSA admission
webhook (https://github.com/kubernetes-sigs/windows-gmsa)
inlines the contents of the GMSA credential spec named by
the GMSACredentialSpecName field.
type: string
gmsaCredentialSpecName:
description: GMSACredentialSpecName is the name of the GMSA
credential spec to use.
type: string
runAsUserName:
description: The UserName in Windows to run the entrypoint
of the container process. Defaults to the user specified
in image metadata if unspecified. May also be set in PodSecurityContext.
If set in both SecurityContext and PodSecurityContext, the
value specified in SecurityContext takes precedence.
type: string
type: object
type: object
x-kubernetes-preserve-unknown-fields: true
serviceAccountName:
description: ServiceAccountName is the name of the ServiceAccount
to use
Expand Down Expand Up @@ -610,12 +475,14 @@ spec:
description: 'ServiceSpec describes the attributes that a user
creates on a service. More info: https://kubernetes.io/docs/concepts/services-networking/service/'
type: object
x-kubernetes-preserve-unknown-fields: true
required:
- spec
type: object
startupProbe:
description: StartupProbe that will be added to CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
storage:
description: Storage is the definition of how storage will be used
by the VMAlertmanager instances.
Expand Down
7 changes: 7 additions & 0 deletions config/crd/bases/operator.victoriametrics.com_vmalerts.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ spec:
affinity:
description: Affinity If specified, the pod's scheduling constraints.
type: object
x-kubernetes-preserve-unknown-fields: true
configMaps:
description: ConfigMaps is a list of ConfigMaps in the same namespace
as the VMAlert object, which shall be mounted into the VMAlert Pods.
Expand Down Expand Up @@ -288,6 +289,7 @@ spec:
required:
- name
type: object
x-kubernetes-preserve-unknown-fields: true
type: array
hostNetwork:
description: HostNetwork controls whether the pod may use the node
Expand Down Expand Up @@ -343,6 +345,7 @@ spec:
livenessProbe:
description: LivenessProbe that will be added CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
logFormat:
description: LogFormat for VMAlert to be configured with. default
or json
Expand Down Expand Up @@ -809,6 +812,7 @@ spec:
readinessProbe:
description: ReadinessProbe that will be added CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
remoteRead:
description: RemoteRead victoria metrics address for loading state
This configuration makes sense only if remoteWrite was configured
Expand Down Expand Up @@ -1393,6 +1397,7 @@ spec:
description: SecurityContext holds pod-level security attributes and
common container settings. This defaults to the default PodSecurityContext.
type: object
x-kubernetes-preserve-unknown-fields: true
serviceAccountName:
description: ServiceAccountName is the name of the ServiceAccount
to use to run the VMAlert Pods.
Expand Down Expand Up @@ -1434,12 +1439,14 @@ spec:
description: 'ServiceSpec describes the attributes that a user
creates on a service. More info: https://kubernetes.io/docs/concepts/services-networking/service/'
type: object
x-kubernetes-preserve-unknown-fields: true
required:
- spec
type: object
startupProbe:
description: StartupProbe that will be added to CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
tolerations:
description: Tolerations If specified, the pod's tolerations.
items:
Expand Down
7 changes: 7 additions & 0 deletions config/crd/bases/operator.victoriametrics.com_vmauths.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ spec:
affinity:
description: Affinity If specified, the pod's scheduling constraints.
type: object
x-kubernetes-preserve-unknown-fields: true
configMaps:
description: ConfigMaps is a list of ConfigMaps in the same namespace
as the VMAuth object, which shall be mounted into the VMAuth Pods.
Expand Down Expand Up @@ -84,6 +85,7 @@ spec:
required:
- name
type: object
x-kubernetes-preserve-unknown-fields: true
type: array
hostAliases:
description: HostAliases provides mapping for ip and hostname, that
Expand Down Expand Up @@ -357,6 +359,7 @@ spec:
livenessProbe:
description: LivenessProbe that will be added CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
logFormat:
description: LogFormat for VMAuth to be configured with.
enum:
Expand Down Expand Up @@ -444,6 +447,7 @@ spec:
readinessProbe:
description: ReadinessProbe that will be added CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
replicaCount:
description: ReplicaCount is the expected size of the VMAuth
format: int32
Expand Down Expand Up @@ -492,6 +496,7 @@ spec:
description: SecurityContext holds pod-level security attributes and
common container settings. This defaults to the default PodSecurityContext.
type: object
x-kubernetes-preserve-unknown-fields: true
serviceAccountName:
description: ServiceAccountName is the name of the ServiceAccount
to use to run the VMAuth Pods.
Expand Down Expand Up @@ -533,12 +538,14 @@ spec:
description: 'ServiceSpec describes the attributes that a user
creates on a service. More info: https://kubernetes.io/docs/concepts/services-networking/service/'
type: object
x-kubernetes-preserve-unknown-fields: true
required:
- spec
type: object
startupProbe:
description: StartupProbe that will be added to CRD pod
type: object
x-kubernetes-preserve-unknown-fields: true
tolerations:
description: Tolerations If specified, the pod's tolerations.
items:
Expand Down
Loading

0 comments on commit 8f79fdd

Please sign in to comment.