Skip to content

Commit abd26ec

Browse files
Merge pull request CrunchyData#312 from xenophenes/pre32
issue 1 - relocate Storage section, reorder sections
2 parents abab648 + 3840fb9 commit abd26ec

File tree

3 files changed

+91
-92
lines changed

3 files changed

+91
-92
lines changed

hugo/content/installation/_index.adoc

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,17 @@ A link:/installation/helm-chart/[Helm Chart] is also provided.
2121
If you're looking to upgrade a current PostgreSQL Operator installation, visit the
2222
link:/installation/upgrading-the-operator/[Upgrading the Operator] page.
2323

24+
There are many ways to configure the operator further. Some sample configurations are
25+
documented on the link:/installation/configuration/[Configuration] page. This includes
26+
setting up security and storage configurations for your environment.
27+
2428
After completing the installation steps, ensure you visit the
2529
link:/installation/deployment/[Deployment] page to deploy the Operator to your
2630
environment.
2731

2832
== Next Steps
2933

30-
There are many ways to configure the operator further. Some sample configurations are
31-
documented on the link:/installation/configuration/[Configuration] page.
32-
33-
You may also want to find out more information on how the operator is designed to work and
34+
You may want to find out more information on how the operator is designed to work and
3435
deploy. This information can be found in the link:/how-it-works/[How It Works] page.
3536

3637
Information can be found on the full scope of commands on the

hugo/content/installation/configuration.adoc

Lines changed: 85 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: "Configuration"
33
date: 2018-04-24T18:26:56-07:00
44
draft: false
5-
weight: 50
5+
weight: 40
66
---
77

88
:toc:
@@ -33,10 +33,10 @@ priviledges, creates the following resources:
3333
The `rbac.yaml` file is also executed a single time when installing
3434
the Operator. This file creates Role scoped privledges which are
3535
granted to the postgres-operator service account. The postgres-operator
36-
service account is used by the *apiserver* and *postgres-operator* containers
36+
service account is used by the *apiserver* and *postgres-operator* containers
3737
to access Kubernetes resources.
3838

39-
Both of these RBAC files are executed by the `deploy/install-rbac.sh`
39+
Both of these RBAC files are executed by the `deploy/install-rbac.sh`
4040
script.
4141

4242
[WARNING]
@@ -194,7 +194,7 @@ FATA[0000] Authentication Failed: 40
194194
....
195195

196196

197-
=== *apiserver* Configuration
197+
=== REST API Configuration
198198

199199
The postgres-operator pod includes the apiserver which is a REST API that pgo
200200
users are able to communicate with.
@@ -216,8 +216,6 @@ The version of PostgreSQL container the Operator will deploy is determined by th
216216
setting in the `$COROOT/conf/apiserver/pgo.yaml` configuration file. By default, this value is
217217
set to the latest release of the Crunchy Container Suite.
218218

219-
==== *pgo.yaml*
220-
221219
The default pgo.yaml configuration file, included in `$COROOT/conf/apiserver/pgo.yaml`,
222220
looks like this -
223221

@@ -365,7 +363,7 @@ for users to use as a starting configuration -
365363
* `pgo.yaml.dynamic` - this configuration specifies *dynamic* storage to be used, namely a *storageclass* that refers to a dynamic provisioning strorage such as StorageOS or Portworx, or GCE.
366364

367365
Note, when Storage Type is *create*, you can specify a storage
368-
configuration setting of *MatchLabels*, when set, this will cause a
366+
configuration setting of *MatchLabels*, when set, this will cause a
369367
*selector* of *name=clustername* to be added into the PVC, this will
370368
let you target specific PV(s) to be matched for this cluster. Note, if a
371369
PV does not match the claim request, then the cluster will not start. Users
@@ -441,7 +439,7 @@ automatically to your disaster recovery site thanks to network storage.
441439

442440
image::/Operator-DR-Storage.png[Operator Storage]
443441

444-
=== *postgres-operator* Container Configuration
442+
=== PostgreSQL Operator Container Configuration
445443

446444
To enable *debug* level messages from the operator pod, set the `CRUNCHY_DEBUG` environment
447445
variable to *true* within its deployment file `deployment.json`.
@@ -454,7 +452,7 @@ templates that are added into the operator deployment by means of a mounted volu
454452
The templates are located in the `$COROOT/conf/postgres-operator` directory and are added into
455453
a config map which is mounted by the operator deployment.
456454

457-
== bash Completion
455+
== Bash Completion
458456

459457
There is a bash completion file that is included for users to try
460458
located in the repository at `examples/pgo-bash-completion`. To use it -
@@ -503,7 +501,7 @@ curl -v -X GET -u readonlyuser:testpass -H "Content-Type: application/json" --in
503501
curl -v -X GET -u readonlyuser:testpass -H "Content-Type: application/json" --insecure https://10.101.155.218:8443/backups/mycluster
504502
....
505503

506-
== Deploying pgpool
504+
== Deploying pgPool
507505

508506
One option with pgo is enabling the creation of a pgpool deployment in addition to the PostgreSQL cluster.
509507
Running pgpool is a logical inclusion when the Kubernetes cluster includes both a primary database in addition
@@ -574,3 +572,80 @@ kubectl delete pod wed10-pgpool-6cc6f6598d-wcnmf
574572

575573
The pgpool deployment will spin up another pgpool which will pick up
576574
the updated secret file.
575+
576+
== Storage Configuration
577+
578+
Most users after they try out the operator will want to create a more customized installation and deployment of the operator using specific storage types.
579+
580+
The operator will work with HostPath, NFS, Dynamic, and GKE Storage.
581+
582+
{{%expand "NFS" %}}
583+
584+
=== NFS
585+
586+
To configure the operator to use NFS for storage, a sample *pgo.yaml.nfs* file is provided. Overlay the default `pgo.yaml` file with that file -
587+
....
588+
cp $COROOT/examples/pgo.yaml.nfs $COROOT/conf/apiserver/pgo.yaml
589+
....
590+
591+
Edit the *pgo.yaml* file to specify the NFS GID that is set for the NFS volume mount you will be using, the default value assumed is *nfsnobody* as the GID (65534). Update the value to meet your NFS security settings.
592+
593+
There is currently no script available to create your NFS Persistent Volumes but you can typically modify the `$COROOT/pv/create-pv.sh` script to work with NFS.
594+
595+
{{% /expand%}}
596+
597+
{{%expand "Dynamic" %}}
598+
599+
=== Dynamic
600+
601+
To configure the operator to use Dynamic Storage classes for storage, a sample *pgo.yaml.storageclass* file is provided. Overlay the default *pgo.yaml* file with that file -
602+
....
603+
cp $COROOT/examples/pgo.yaml.storageclass $COROOT/conf/apiserver/pgo.yaml
604+
....
605+
606+
Edit the *pgo.yaml* file to specify the storage class you will be using, the default value assumed is *standard* which is the name used by default within a GKE Kube cluster deployment. Update the value to match your storage classes.
607+
608+
Notice that the *FsGroup* setting is required for most block storage and is set to the value of *26* since the PostgreSQL container runs as UID *26*.
609+
610+
{{% /expand%}}
611+
612+
{{%expand "GKE" %}}
613+
614+
=== GKE
615+
616+
Some notes for setting up GKE for the Operator deployment.
617+
618+
==== Install Kubectl
619+
620+
On your host you will be working from, install the kubectl command -
621+
622+
https://kubernetes.io/docs/tasks/tools/install-kubectl/
623+
624+
==== GCP
625+
626+
* Select your project
627+
* Create a Kube cluster in that project
628+
629+
By default a storage class called *standard* is created.
630+
631+
==== Install GCloud
632+
633+
To access the Kubernetes cluster, install the gcloud utility -
634+
635+
....
636+
https://cloud.google.com/sdk/downloads
637+
cd google-cloud-sdk
638+
./install.sh
639+
....
640+
641+
==== Configure Kubectl for Cluster Access
642+
643+
....
644+
gcloud auth login
645+
646+
gcloud container clusters get-credentials jeff-quickstart --zone us-central1-a --project crunchy-dev-test
647+
648+
kubectl get storageclass
649+
....
650+
651+
{{% /expand%}}

hugo/content/installation/deployment.adoc

Lines changed: 1 addition & 78 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: "Deployment"
33
date: 2018-04-26T15:26:40-07:00
44
draft: false
5-
weight: 40
5+
weight: 50
66
---
77

88
:toc:
@@ -136,83 +136,6 @@ apiserver version 3.2
136136

137137
Operator commands are documented on the link:/getting-started/[Getting Started] page.
138138

139-
== Storage Configuration
140-
141-
Most users after they try out the operator will want to create a more customized installation and deployment of the operator using specific storage types.
142-
143-
The operator will work with HostPath, NFS, Dynamic, and GKE Storage.
144-
145-
{{%expand "NFS" %}}
146-
147-
=== NFS
148-
149-
To configure the operator to use NFS for storage, a sample *pgo.yaml.nfs* file is provided. Overlay the default `pgo.yaml` file with that file -
150-
....
151-
cp $COROOT/examples/pgo.yaml.nfs $COROOT/conf/apiserver/pgo.yaml
152-
....
153-
154-
Edit the *pgo.yaml* file to specify the NFS GID that is set for the NFS volume mount you will be using, the default value assumed is *nfsnobody* as the GID (65534). Update the value to meet your NFS security settings.
155-
156-
There is currently no script available to create your NFS Persistent Volumes but you can typically modify the `$COROOT/pv/create-pv.sh` script to work with NFS.
157-
158-
{{% /expand%}}
159-
160-
{{%expand "Dynamic" %}}
161-
162-
=== Dynamic
163-
164-
To configure the operator to use Dynamic Storage classes for storage, a sample *pgo.yaml.storageclass* file is provided. Overlay the default *pgo.yaml* file with that file -
165-
....
166-
cp $COROOT/examples/pgo.yaml.storageclass $COROOT/conf/apiserver/pgo.yaml
167-
....
168-
169-
Edit the *pgo.yaml* file to specify the storage class you will be using, the default value assumed is *standard* which is the name used by default within a GKE Kube cluster deployment. Update the value to match your storage classes.
170-
171-
Notice that the *FsGroup* setting is required for most block storage and is set to the value of *26* since the PostgreSQL container runs as UID *26*.
172-
173-
{{% /expand%}}
174-
175-
{{%expand "GKE" %}}
176-
177-
=== GKE
178-
179-
Some notes for setting up GKE for the Operator deployment.
180-
181-
==== Install Kubectl
182-
183-
On your host you will be working from, install the kubectl command -
184-
185-
https://kubernetes.io/docs/tasks/tools/install-kubectl/
186-
187-
==== GCP
188-
189-
* Select your project
190-
* Create a Kube cluster in that project
191-
192-
By default a storage class called *standard* is created.
193-
194-
==== Install GCloud
195-
196-
To access the Kubernetes cluster, install the gcloud utility -
197-
198-
....
199-
https://cloud.google.com/sdk/downloads
200-
cd google-cloud-sdk
201-
./install.sh
202-
....
203-
204-
==== Configure Kubectl for Cluster Access
205-
206-
....
207-
gcloud auth login
208-
209-
gcloud container clusters get-credentials jeff-quickstart --zone us-central1-a --project crunchy-dev-test
210-
211-
kubectl get storageclass
212-
....
213-
214-
{{% /expand%}}
215-
216139
== Next Steps
217140

218141
There are many ways to configure the operator further. Some sample configurations are

0 commit comments

Comments
 (0)