post polishing for latest PRs
This commit is contained in:
parent
3b6dc4f92d
commit
4a99ea61e9
|
|
@ -263,6 +263,11 @@ spec:
|
||||||
type: boolean
|
type: boolean
|
||||||
enable_replica_load_balancer:
|
enable_replica_load_balancer:
|
||||||
type: boolean
|
type: boolean
|
||||||
|
external_traffic_policy:
|
||||||
|
type: string
|
||||||
|
enum:
|
||||||
|
- "Cluster"
|
||||||
|
- "Local"
|
||||||
master_dns_name_format:
|
master_dns_name_format:
|
||||||
type: string
|
type: string
|
||||||
replica_dns_name_format:
|
replica_dns_name_format:
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,15 @@
|
||||||
|
{{- if .Values.priorityClassName }}
|
||||||
|
apiVersion: scheduling.k8s.io/v1
|
||||||
|
description: 'Use only for databases controlled by Postgres operator'
|
||||||
|
kind: PriorityClass
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: {{ template "postgres-operator.name" . }}
|
||||||
|
helm.sh/chart: {{ template "postgres-operator.chart" . }}
|
||||||
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||||
|
name: {{ .Values.priorityClassName }}
|
||||||
|
preemptionPolicy: PreemptLowerPriority
|
||||||
|
globalDefault: false
|
||||||
|
value: 1000000
|
||||||
|
{{- end }}
|
||||||
|
|
@ -183,6 +183,8 @@ configLoadBalancer:
|
||||||
enable_master_load_balancer: false
|
enable_master_load_balancer: false
|
||||||
# toggles service type load balancer pointing to the replica pod of the cluster
|
# toggles service type load balancer pointing to the replica pod of the cluster
|
||||||
enable_replica_load_balancer: false
|
enable_replica_load_balancer: false
|
||||||
|
# define external traffic policy for the load balancer
|
||||||
|
external_traffic_policy: "Cluster"
|
||||||
# defines the DNS name string template for the master load balancer cluster
|
# defines the DNS name string template for the master load balancer cluster
|
||||||
master_dns_name_format: "{cluster}.{team}.{hostedzone}"
|
master_dns_name_format: "{cluster}.{team}.{hostedzone}"
|
||||||
# defines the DNS name string template for the replica load balancer cluster
|
# defines the DNS name string template for the replica load balancer cluster
|
||||||
|
|
|
||||||
|
|
@ -172,6 +172,8 @@ configLoadBalancer:
|
||||||
enable_master_load_balancer: "false"
|
enable_master_load_balancer: "false"
|
||||||
# toggles service type load balancer pointing to the replica pod of the cluster
|
# toggles service type load balancer pointing to the replica pod of the cluster
|
||||||
enable_replica_load_balancer: "false"
|
enable_replica_load_balancer: "false"
|
||||||
|
# define external traffic policy for the load balancer
|
||||||
|
external_traffic_policy: "Cluster"
|
||||||
# defines the DNS name string template for the master load balancer cluster
|
# defines the DNS name string template for the master load balancer cluster
|
||||||
master_dns_name_format: '{cluster}.{team}.{hostedzone}'
|
master_dns_name_format: '{cluster}.{team}.{hostedzone}'
|
||||||
# defines the DNS name string template for the replica load balancer cluster
|
# defines the DNS name string template for the replica load balancer cluster
|
||||||
|
|
|
||||||
|
|
@ -434,6 +434,12 @@ CRD-based configuration.
|
||||||
Those options affect the behavior of load balancers created by the operator.
|
Those options affect the behavior of load balancers created by the operator.
|
||||||
In the CRD-based configuration they are grouped under the `load_balancer` key.
|
In the CRD-based configuration they are grouped under the `load_balancer` key.
|
||||||
|
|
||||||
|
* **custom_service_annotations**
|
||||||
|
This key/value map provides a list of annotations that get attached to each
|
||||||
|
service of a cluster created by the operator. If the annotation key is also
|
||||||
|
provided by the cluster definition, the manifest value is used.
|
||||||
|
Optional.
|
||||||
|
|
||||||
* **db_hosted_zone**
|
* **db_hosted_zone**
|
||||||
DNS zone for the cluster DNS name when the load balancer is configured for
|
DNS zone for the cluster DNS name when the load balancer is configured for
|
||||||
the cluster. Only used when combined with
|
the cluster. Only used when combined with
|
||||||
|
|
@ -450,11 +456,8 @@ In the CRD-based configuration they are grouped under the `load_balancer` key.
|
||||||
cluster. Can be overridden by individual cluster settings. The default is
|
cluster. Can be overridden by individual cluster settings. The default is
|
||||||
`false`.
|
`false`.
|
||||||
|
|
||||||
* **custom_service_annotations**
|
* **external_traffic_policy** defines external traffic policy for load
|
||||||
This key/value map provides a list of annotations that get attached to each
|
balancers. Allowed values are `Cluster` (default) and `Local`.
|
||||||
service of a cluster created by the operator. If the annotation key is also
|
|
||||||
provided by the cluster definition, the manifest value is used.
|
|
||||||
Optional.
|
|
||||||
|
|
||||||
* **master_dns_name_format** defines the DNS name string template for the
|
* **master_dns_name_format** defines the DNS name string template for the
|
||||||
master load balancer cluster. The default is
|
master load balancer cluster. The default is
|
||||||
|
|
@ -470,9 +473,6 @@ In the CRD-based configuration they are grouped under the `load_balancer` key.
|
||||||
replaced with the hosted zone (the value of the `db_hosted_zone` parameter).
|
replaced with the hosted zone (the value of the `db_hosted_zone` parameter).
|
||||||
No other placeholders are allowed.
|
No other placeholders are allowed.
|
||||||
|
|
||||||
* **external_traffic_policy** define external traffic policy for the load
|
|
||||||
balancer, it will default to `Cluster` if undefined.
|
|
||||||
|
|
||||||
## AWS or GCP interaction
|
## AWS or GCP interaction
|
||||||
|
|
||||||
The options in this group configure operator interactions with non-Kubernetes
|
The options in this group configure operator interactions with non-Kubernetes
|
||||||
|
|
|
||||||
|
|
@ -47,6 +47,7 @@ data:
|
||||||
# enable_team_superuser: "false"
|
# enable_team_superuser: "false"
|
||||||
enable_teams_api: "false"
|
enable_teams_api: "false"
|
||||||
# etcd_host: ""
|
# etcd_host: ""
|
||||||
|
external_traffic_policy: "Cluster"
|
||||||
# gcp_credentials: ""
|
# gcp_credentials: ""
|
||||||
# kubernetes_use_configmaps: "false"
|
# kubernetes_use_configmaps: "false"
|
||||||
# infrastructure_roles_secret_name: "postgresql-infrastructure-roles"
|
# infrastructure_roles_secret_name: "postgresql-infrastructure-roles"
|
||||||
|
|
@ -80,12 +81,12 @@ data:
|
||||||
# pod_environment_secret: "my-custom-secret"
|
# pod_environment_secret: "my-custom-secret"
|
||||||
pod_label_wait_timeout: 10m
|
pod_label_wait_timeout: 10m
|
||||||
pod_management_policy: "ordered_ready"
|
pod_management_policy: "ordered_ready"
|
||||||
|
# pod_priority_class_name: "postgres-pod-priority"
|
||||||
pod_role_label: spilo-role
|
pod_role_label: spilo-role
|
||||||
# pod_service_account_definition: ""
|
# pod_service_account_definition: ""
|
||||||
pod_service_account_name: "postgres-pod"
|
pod_service_account_name: "postgres-pod"
|
||||||
# pod_service_account_role_binding_definition: ""
|
# pod_service_account_role_binding_definition: ""
|
||||||
pod_terminate_grace_period: 5m
|
pod_terminate_grace_period: 5m
|
||||||
# pod_priority_class_name: "postgres-pod-priority"
|
|
||||||
# postgres_superuser_teams: "postgres_superusers"
|
# postgres_superuser_teams: "postgres_superusers"
|
||||||
# protected_role_names: "admin"
|
# protected_role_names: "admin"
|
||||||
ready_wait_interval: 3s
|
ready_wait_interval: 3s
|
||||||
|
|
|
||||||
|
|
@ -265,6 +265,11 @@ spec:
|
||||||
type: boolean
|
type: boolean
|
||||||
enable_replica_load_balancer:
|
enable_replica_load_balancer:
|
||||||
type: boolean
|
type: boolean
|
||||||
|
external_traffic_policy:
|
||||||
|
type: string
|
||||||
|
enum:
|
||||||
|
- "Cluster"
|
||||||
|
- "Local"
|
||||||
master_dns_name_format:
|
master_dns_name_format:
|
||||||
type: string
|
type: string
|
||||||
replica_dns_name_format:
|
replica_dns_name_format:
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ configuration:
|
||||||
# pod_environment_configmap: "default/my-custom-config"
|
# pod_environment_configmap: "default/my-custom-config"
|
||||||
# pod_environment_secret: "my-custom-secret"
|
# pod_environment_secret: "my-custom-secret"
|
||||||
pod_management_policy: "ordered_ready"
|
pod_management_policy: "ordered_ready"
|
||||||
# pod_priority_class_name: ""
|
# pod_priority_class_name: "postgres-pod-priority"
|
||||||
pod_role_label: spilo-role
|
pod_role_label: spilo-role
|
||||||
# pod_service_account_definition: ""
|
# pod_service_account_definition: ""
|
||||||
pod_service_account_name: postgres-pod
|
pod_service_account_name: postgres-pod
|
||||||
|
|
@ -90,12 +90,13 @@ configuration:
|
||||||
resource_check_interval: 3s
|
resource_check_interval: 3s
|
||||||
resource_check_timeout: 10m
|
resource_check_timeout: 10m
|
||||||
load_balancer:
|
load_balancer:
|
||||||
# db_hosted_zone: ""
|
|
||||||
enable_master_load_balancer: false
|
|
||||||
enable_replica_load_balancer: false
|
|
||||||
# custom_service_annotations:
|
# custom_service_annotations:
|
||||||
# keyx: valuex
|
# keyx: valuex
|
||||||
# keyy: valuey
|
# keyy: valuey
|
||||||
|
# db_hosted_zone: ""
|
||||||
|
enable_master_load_balancer: false
|
||||||
|
enable_replica_load_balancer: false
|
||||||
|
external_traffic_policy: "Cluster"
|
||||||
master_dns_name_format: "{cluster}.{team}.{hostedzone}"
|
master_dns_name_format: "{cluster}.{team}.{hostedzone}"
|
||||||
replica_dns_name_format: "{cluster}-repl.{team}.{hostedzone}"
|
replica_dns_name_format: "{cluster}-repl.{team}.{hostedzone}"
|
||||||
aws_or_gcp:
|
aws_or_gcp:
|
||||||
|
|
|
||||||
|
|
@ -1135,12 +1135,6 @@ var OperatorConfigCRDResourceValidation = apiextv1beta1.CustomResourceValidation
|
||||||
"enable_replica_load_balancer": {
|
"enable_replica_load_balancer": {
|
||||||
Type: "boolean",
|
Type: "boolean",
|
||||||
},
|
},
|
||||||
"master_dns_name_format": {
|
|
||||||
Type: "string",
|
|
||||||
},
|
|
||||||
"replica_dns_name_format": {
|
|
||||||
Type: "string",
|
|
||||||
},
|
|
||||||
"external_traffic_policy": {
|
"external_traffic_policy": {
|
||||||
Type: "string",
|
Type: "string",
|
||||||
Enum: []apiextv1beta1.JSON{
|
Enum: []apiextv1beta1.JSON{
|
||||||
|
|
@ -1152,6 +1146,12 @@ var OperatorConfigCRDResourceValidation = apiextv1beta1.CustomResourceValidation
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
"master_dns_name_format": {
|
||||||
|
Type: "string",
|
||||||
|
},
|
||||||
|
"replica_dns_name_format": {
|
||||||
|
Type: "string",
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
"aws_or_gcp": {
|
"aws_or_gcp": {
|
||||||
|
|
|
||||||
|
|
@ -177,10 +177,9 @@ type Config struct {
|
||||||
EnablePodAntiAffinity bool `name:"enable_pod_antiaffinity" default:"false"`
|
EnablePodAntiAffinity bool `name:"enable_pod_antiaffinity" default:"false"`
|
||||||
PodAntiAffinityTopologyKey string `name:"pod_antiaffinity_topology_key" default:"kubernetes.io/hostname"`
|
PodAntiAffinityTopologyKey string `name:"pod_antiaffinity_topology_key" default:"kubernetes.io/hostname"`
|
||||||
StorageResizeMode string `name:"storage_resize_mode" default:"ebs"`
|
StorageResizeMode string `name:"storage_resize_mode" default:"ebs"`
|
||||||
// ExternalTrafficPolicy for load balancer
|
|
||||||
ExternalTrafficPolicy string `name:"external_traffic_policy" default:"Cluster"`
|
|
||||||
// deprecated and kept for backward compatibility
|
// deprecated and kept for backward compatibility
|
||||||
EnableLoadBalancer *bool `name:"enable_load_balancer"`
|
EnableLoadBalancer *bool `name:"enable_load_balancer"`
|
||||||
|
ExternalTrafficPolicy string `name:"external_traffic_policy" default:"Cluster"`
|
||||||
MasterDNSNameFormat StringTemplate `name:"master_dns_name_format" default:"{cluster}.{team}.{hostedzone}"`
|
MasterDNSNameFormat StringTemplate `name:"master_dns_name_format" default:"{cluster}.{team}.{hostedzone}"`
|
||||||
ReplicaDNSNameFormat StringTemplate `name:"replica_dns_name_format" default:"{cluster}-repl.{team}.{hostedzone}"`
|
ReplicaDNSNameFormat StringTemplate `name:"replica_dns_name_format" default:"{cluster}-repl.{team}.{hostedzone}"`
|
||||||
PDBNameFormat StringTemplate `name:"pdb_name_format" default:"postgres-{cluster}-pdb"`
|
PDBNameFormat StringTemplate `name:"pdb_name_format" default:"postgres-{cluster}-pdb"`
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue