-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
ranchodeluxe
committed
Jun 6, 2024
1 parent
4b190b3
commit 0beff9d
Showing
27 changed files
with
19,158 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
[submodule "helm-chart/charts/postgres-operator-examples"] | ||
path = helm-chart/charts/postgres-operator-examples | ||
[submodule "helm-chart/eoapi/postgres-operator-examples"] | ||
path = helm-chart/eoapi/postgres-operator-examples | ||
url = [email protected]:developmentseed/postgres-operator-examples.git |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
dependencies: | ||
- name: install | ||
repository: "" | ||
version: 5.5.2 | ||
- name: postgres | ||
repository: "" | ||
version: 5.5.2 | ||
digest: sha256:2f94d30d389d9a0f84718c6c157fc6936879e21cd383283622c25b9190aff868 | ||
generated: "2024-06-06T10:32:29.776072-07:00" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# https://github.com/github/linguist/issues/4905 | ||
# https://github.com/github/linguist/issues/5092#issuecomment-730262298 | ||
/templates/*.tpl linguist-language=handlebars |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
.git* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
apiVersion: v2 | ||
name: pgo | ||
description: Installer for PGO, the open source Postgres Operator from Crunchy Data | ||
|
||
type: application | ||
# The version below should match the version on the PostgresCluster CRD | ||
version: 5.5.2 | ||
appVersion: 5.5.2 |
1,532 changes: 1,532 additions & 0 deletions
1,532
helm-chart/eoapi/charts/install/crds/postgres-operator.crunchydata.com_pgadmins.yaml
Large diffs are not rendered by default.
Oops, something went wrong.
1,075 changes: 1,075 additions & 0 deletions
1,075
helm-chart/eoapi/charts/install/crds/postgres-operator.crunchydata.com_pgupgrades.yaml
Large diffs are not rendered by default.
Oops, something went wrong.
15,461 changes: 15,461 additions & 0 deletions
15,461
helm-chart/eoapi/charts/install/crds/postgres-operator.crunchydata.com_postgresclusters.yaml
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
Thank you for deploying PGO v{{ .Chart.AppVersion }}! | ||
|
||
(((((((((((((((((((((( | ||
(((((((((((((%%%%%%%((((((((((((((( | ||
(((((((((((%%% %%%%(((((((((((( | ||
(((((((((((%%( (((( ( %%%((((((((((( | ||
(((((((((((((%% (( ,(( %%%((((((((((( | ||
(((((((((((((((%% *%%/ %%%%%%%(((((((((( | ||
(((((((((((((((((((%%(( %%%%%%%%%%#(((((%%%%%%%%%%#(((((((((((( | ||
((((((((((((((((((%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%(((((((((((((( | ||
*((((((((((((((((((((%%%%%% /%%%%%%%%%%%%%%%%%%%(((((((((((((((( | ||
(((((((((((((((((((((((%%%/ .%, %%%((((((((((((((((((, | ||
((((((((((((((((((((((% %#((((((((((((((((( | ||
(((((((((((((((%%%%%% #%((((((((((((((((( | ||
((((((((((((((%% %%(((((((((((((((, | ||
((((((((((((%%%#% % %%((((((((((((((( | ||
((((((((((((%. % % #(((((((((((((( | ||
(((((((((((%% % %%* %((((((((((((( | ||
#(###(###(#%% %%% %% %%% #%%#(###(###(# | ||
###########%%%%% /%%%%%%%%%%%%% %% %%%%% ,%%####### | ||
###############%% %%%%%% %%% %%%%%%%% %%##### | ||
################%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% %%## | ||
################%% %%%%%%%%%%%%%%%%% %%%% % | ||
##############%# %% (%%%%%%% %%%%%% | ||
#############% %%%%% %%%%%%%%%%% | ||
###########% %%%%%%%%%%% %%%%%%%%% | ||
#########%% %% %%%%%%%%%%%%%%%# | ||
########%% %% %%%%%%%%% | ||
######%% %% %%%%%% | ||
####%%% %%%%% % | ||
%% %%%% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,100 @@ | ||
{{/* | ||
Create chart name and version as used by the chart label. | ||
*/}} | ||
{{- define "install.chart" -}} | ||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} | ||
{{- end }} | ||
|
||
{{/* | ||
Crunchy labels | ||
*/}} | ||
{{- define "install.clusterLabels" -}} | ||
postgres-operator.crunchydata.com/control-plane: {{ .Chart.Name }} | ||
{{- end }} | ||
|
||
{{/* | ||
Common labels | ||
*/}} | ||
{{- define "install.labels" -}} | ||
helm.sh/chart: {{ include "install.chart" . }} | ||
app.kubernetes.io/name: {{ .Chart.Name }} | ||
app.kubernetes.io/instance: {{ .Release.Name }} | ||
{{- if .Chart.AppVersion }} | ||
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} | ||
{{- end }} | ||
app.kubernetes.io/managed-by: {{ .Release.Service }} | ||
{{- end }} | ||
|
||
{{/* | ||
Custom Labels | ||
*/}} | ||
{{- define "install.customPodLabels" -}} | ||
{{- if .Values.customPodLabels -}} | ||
{{ toYaml .Values.customPodLabels }} | ||
{{- end}} | ||
{{- end }} | ||
|
||
{{/* | ||
Create the name of the service account to use | ||
*/}} | ||
{{- define "install.serviceAccountName" -}} | ||
{{ .Chart.Name }} | ||
{{- end }} | ||
|
||
{{/* | ||
Create the name of the Role/ClusterRole to use | ||
*/}} | ||
{{- define "install.roleName" -}} | ||
{{ .Chart.Name }} | ||
{{- end }} | ||
|
||
{{/* | ||
Create the name of the RoleBinding/ClusterRoleBinding to use | ||
*/}} | ||
{{- define "install.roleBindingName" -}} | ||
{{ .Chart.Name }} | ||
{{- end }} | ||
|
||
{{/* | ||
Create the kind for rolebindings. Will be RoleBinding in single | ||
namespace mode or ClusterRoleBinding by default. | ||
*/}} | ||
{{- define "install.roleBindingKind" -}} | ||
{{- if .Values.singleNamespace -}} | ||
RoleBinding | ||
{{- else -}} | ||
ClusterRoleBinding | ||
{{- end }} | ||
{{- end }} | ||
|
||
{{/* | ||
Create the kind for role. Will be Role in single | ||
namespace mode or ClusterRole by default. | ||
*/}} | ||
{{- define "install.roleKind" -}} | ||
{{- if .Values.singleNamespace -}} | ||
Role | ||
{{- else -}} | ||
ClusterRole | ||
{{- end }} | ||
{{- end }} | ||
|
||
{{- define "install.imagePullSecrets" -}} | ||
{{/* Earlier versions required the full structure of PodSpec.ImagePullSecrets */}} | ||
{{- if .Values.imagePullSecrets }} | ||
imagePullSecrets: | ||
{{ toYaml .Values.imagePullSecrets }} | ||
{{- else if .Values.imagePullSecretNames }} | ||
imagePullSecrets: | ||
{{- range .Values.imagePullSecretNames }} | ||
- name: {{ . | quote }} | ||
{{- end }}{{/* range */}} | ||
{{- end }}{{/* if */}} | ||
{{- end }}{{/* define */}} | ||
|
||
{{- define "install.relatedImages" -}} | ||
{{- range $id, $object := .Values.relatedImages }} | ||
- name: RELATED_IMAGE_{{ $id | upper }} | ||
value: {{ $object.image | quote }} | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
--- | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: {{ .Chart.Name }} | ||
labels: | ||
{{- include "install.labels" . | nindent 4 }} | ||
{{- include "install.clusterLabels" . | nindent 4 }} | ||
spec: | ||
replicas: 1 | ||
strategy: { type: Recreate } | ||
selector: | ||
matchLabels: | ||
{{- include "install.clusterLabels" . | nindent 6 }} | ||
template: | ||
metadata: | ||
labels: | ||
{{- include "install.clusterLabels" . | nindent 8 }} | ||
{{- include "install.customPodLabels" . | nindent 8 }} | ||
spec: | ||
{{- include "install.imagePullSecrets" . | indent 6 }} | ||
serviceAccountName: {{ include "install.serviceAccountName" . }} | ||
containers: | ||
- name: operator | ||
image: {{ required ".Values.controllerImages.cluster is required" .Values.controllerImages.cluster | quote }} | ||
env: | ||
- name: CRUNCHY_DEBUG | ||
value: {{ .Values.debug | ne false | quote }} | ||
- name: PGO_NAMESPACE | ||
valueFrom: { fieldRef: { apiVersion: v1, fieldPath: metadata.namespace } } | ||
{{- if .Values.singleNamespace }} | ||
- name: PGO_TARGET_NAMESPACE | ||
valueFrom: { fieldRef: { apiVersion: v1, fieldPath: metadata.namespace } } | ||
{{- end }} | ||
{{- if .Values.workers }} | ||
- name: PGO_WORKERS | ||
value: {{ .Values.workers | quote }} | ||
{{- end }} | ||
{{- include "install.relatedImages" . | indent 8 }} | ||
{{- if .Values.disable_check_for_upgrades }} | ||
- name: CHECK_FOR_UPGRADES | ||
value: "false" | ||
{{- end }} | ||
{{- if .Values.resources.controller }} | ||
resources: | ||
{{- toYaml .Values.resources.controller | nindent 10 }} | ||
{{- end }} | ||
securityContext: | ||
allowPrivilegeEscalation: false | ||
capabilities: { drop: [ALL] } | ||
readOnlyRootFilesystem: true | ||
runAsNonRoot: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,149 @@ | ||
--- | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: {{ include "install.roleKind" . }} | ||
metadata: | ||
name: {{ include "install.roleName" . }} | ||
labels: | ||
{{- include "install.labels" . | nindent 4 }} | ||
{{- include "install.clusterLabels" . | nindent 4 }} | ||
rules: | ||
- apiGroups: | ||
- '' | ||
resources: | ||
- configmaps | ||
- persistentvolumeclaims | ||
- secrets | ||
- services | ||
verbs: | ||
- create | ||
- delete | ||
- get | ||
- list | ||
- patch | ||
- watch | ||
- apiGroups: | ||
- '' | ||
resources: | ||
- endpoints | ||
verbs: | ||
- create | ||
- delete | ||
- deletecollection | ||
- get | ||
- list | ||
- patch | ||
- watch | ||
- apiGroups: | ||
- '' | ||
resources: | ||
- endpoints/restricted | ||
- pods/exec | ||
verbs: | ||
- create | ||
- apiGroups: | ||
- '' | ||
resources: | ||
- events | ||
verbs: | ||
- create | ||
- patch | ||
- apiGroups: | ||
- '' | ||
resources: | ||
- pods | ||
verbs: | ||
- delete | ||
- get | ||
- list | ||
- patch | ||
- watch | ||
- apiGroups: | ||
- '' | ||
resources: | ||
- serviceaccounts | ||
verbs: | ||
- create | ||
- get | ||
- list | ||
- patch | ||
- watch | ||
- apiGroups: | ||
- apps | ||
resources: | ||
- deployments | ||
- statefulsets | ||
verbs: | ||
- create | ||
- delete | ||
- get | ||
- list | ||
- patch | ||
- watch | ||
- apiGroups: | ||
- batch | ||
resources: | ||
- cronjobs | ||
- jobs | ||
verbs: | ||
- create | ||
- delete | ||
- get | ||
- list | ||
- patch | ||
- watch | ||
- apiGroups: | ||
- policy | ||
resources: | ||
- poddisruptionbudgets | ||
verbs: | ||
- create | ||
- delete | ||
- get | ||
- list | ||
- patch | ||
- watch | ||
- apiGroups: | ||
- postgres-operator.crunchydata.com | ||
resources: | ||
- pgadmins | ||
- pgupgrades | ||
verbs: | ||
- get | ||
- list | ||
- watch | ||
- apiGroups: | ||
- postgres-operator.crunchydata.com | ||
resources: | ||
- pgadmins/finalizers | ||
- pgupgrades/finalizers | ||
- postgresclusters/finalizers | ||
verbs: | ||
- update | ||
- apiGroups: | ||
- postgres-operator.crunchydata.com | ||
resources: | ||
- pgadmins/status | ||
- pgupgrades/status | ||
- postgresclusters/status | ||
verbs: | ||
- patch | ||
- apiGroups: | ||
- postgres-operator.crunchydata.com | ||
resources: | ||
- postgresclusters | ||
verbs: | ||
- get | ||
- list | ||
- patch | ||
- watch | ||
- apiGroups: | ||
- rbac.authorization.k8s.io | ||
resources: | ||
- rolebindings | ||
- roles | ||
verbs: | ||
- create | ||
- get | ||
- list | ||
- patch | ||
- watch |
16 changes: 16 additions & 0 deletions
16
helm-chart/eoapi/charts/install/templates/role_binding.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
--- | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: {{ include "install.roleBindingKind" . }} | ||
metadata: | ||
name: {{ include "install.roleBindingName" . }} | ||
labels: | ||
{{- include "install.labels" . | nindent 4 }} | ||
{{- include "install.clusterLabels" . | nindent 4 }} | ||
roleRef: | ||
apiGroup: rbac.authorization.k8s.io | ||
kind: {{ include "install.roleKind" . }} | ||
name: {{ include "install.roleName" . }} | ||
subjects: | ||
- kind: ServiceAccount | ||
name: {{ include "install.serviceAccountName" . }} | ||
namespace: {{ .Release.Namespace }} |
Oops, something went wrong.