Skip to content

Commit c0017d8

Browse files
author
Jeff McCormick
committed
Merge branch 'master' of github.com:CrunchyData/postgres-operator
2 parents 1aa8ecb + c096052 commit c0017d8

File tree

19 files changed

+156
-54
lines changed

19 files changed

+156
-54
lines changed

chart/postgres-operator/templates/deployment.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ spec:
1515
app: {{ template "postgres-operator.name" . }}
1616
release: {{ .Release.Name }}
1717
spec:
18+
serviceAccountName: postgres-operator
1819
containers:
1920
- name: {{ .Chart.Name }}-apiserver
2021
image: "{{ .Values.env.co_image_prefix }}/pgo-apiserver:{{ .Values.env.co_image_tag }}"

chart/postgres-operator/values.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,10 @@ resources:
2727
memory: 128Mi
2828

2929
serviceAccount:
30+
name: "postgres-operator"
3031
create: "true"
3132

3233
rbac:
3334
create: "true"
3435

35-
nameOverride: "pgo"
36+
nameOverride: "pgo"

docs/contributing/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ <h1>Contributing</h1>
220220

221221

222222
<div class="paragraph">
223-
<p>v3.1, 2018-06-13</p>
223+
<p>v3.1, 2018-06-22</p>
224224
</div>
225225
<div class="sect1">
226226
<h2 id="_getting_started">Getting Started</h2>

docs/getting-started/index.html

Lines changed: 41 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@ <h1>Getting Started</h1>
225225
<li><a href="#_pgo_commands">pgo Commands</a>
226226
<ul class="sectlevel2">
227227
<li><a href="#_pgo_version">pgo version</a></li>
228+
<li><a href="#_pgo_show_config">pgo show config</a></li>
228229
<li><a href="#_pgo_create_cluster">pgo create cluster</a></li>
229230
<li><a href="#_pgo_backup">pgo backup</a></li>
230231
<li><a href="#_pgo_delete_backup">pgo delete backup</a></li>
@@ -244,12 +245,13 @@ <h1>Getting Started</h1>
244245
<li><a href="#_pgo_failover">pgo failover</a></li>
245246
<li><a href="#_pgo_df">pgo df</a></li>
246247
<li><a href="#_pgo_status">pgo status</a></li>
248+
<li><a href="#_pgo_show_config_2">pgo show config</a></li>
247249
</ul>
248250
</li>
249251
</ul>
250252
</div>
251253
<div class="paragraph">
252-
<p>v3.1, 2018-06-13</p>
254+
<p>v3.1, 2018-06-22</p>
253255
</div>
254256
<div class="sect1">
255257
<h2 id="_pgo_commands">pgo Commands</h2>
@@ -280,6 +282,17 @@ <h3 id="_pgo_version">pgo version</h3>
280282
</div>
281283
</div>
282284
<div class="sect2">
285+
<h3 id="_pgo_show_config">pgo show config</h3>
286+
<div class="paragraph">
287+
<p>To see what configuration you are running against within the Operator, use the following -</p>
288+
</div>
289+
<div class="literalblock">
290+
<div class="content">
291+
<pre>pgo show config</pre>
292+
</div>
293+
</div>
294+
</div>
295+
<div class="sect2">
283296
<h3 id="_pgo_create_cluster">pgo create cluster</h3>
284297
<div class="paragraph">
285298
<p>To create a database, use the following -</p>
@@ -926,6 +939,18 @@ <h3 id="_pgo_user">pgo user</h3>
926939
</div>
927940
</div>
928941
<div class="paragraph">
942+
<p>To create a new Postgres user to the <strong>mycluster</strong> cluster that has credentials created with Kubernetes Secrets, use the <strong>--managed</strong> flag:</p>
943+
</div>
944+
<div class="literalblock">
945+
<div class="content">
946+
<pre>pgo create user sally --managed --selector=name=mycluster</pre>
947+
</div>
948+
</div>
949+
<div class="paragraph">
950+
<p>A <strong>managed</strong> account is one that the Operator can manipulate as well; this means that when you run <code>pgo show cluster mycluster --show-secrets</code>
951+
their credentials are visible, when you run <code>pgo test mycluster</code> the account is tested with the other default accounts, etc.</p>
952+
</div>
953+
<div class="paragraph">
929954
<p>To change the password for a user in the <strong>mycluster</strong> cluster:</p>
930955
</div>
931956
<div class="literalblock">
@@ -950,7 +975,7 @@ <h3 id="_pgo_user">pgo user</h3>
950975
</div>
951976
<div class="literalblock">
952977
<div class="content">
953-
<pre>pgo create user user1 --valid-days=30 --managed --db=userdb --selector=name=xraydb1</pre>
978+
<pre>pgo create user user1 --valid-days=30 --db=userdb --selector=name=xraydb1</pre>
954979
</div>
955980
</div>
956981
<div class="paragraph">
@@ -1218,6 +1243,20 @@ <h3 id="_pgo_status">pgo status</h3>
12181243
</div>
12191244
</div>
12201245
</div>
1246+
<div class="sect2">
1247+
<h3 id="_pgo_show_config_2">pgo show config</h3>
1248+
<div class="paragraph">
1249+
<p>The <code>pgo show config</code> command displays the running operator configuration
1250+
parameters that dictate the setup and user defined configuration of the
1251+
operator. This command can be useful for sharing your configuration or
1252+
verifying the setup is as expected.</p>
1253+
</div>
1254+
<div class="literalblock">
1255+
<div class="content">
1256+
<pre>pgo show config</pre>
1257+
</div>
1258+
</div>
1259+
</div>
12211260
</div>
12221261
</div>
12231262

docs/how-it-works/index.html

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ <h1>How it Works</h1>
250250
</ul>
251251
</div>
252252
<div class="paragraph">
253-
<p>v3.1, 2018-06-13</p>
253+
<p>v3.1, 2018-06-22</p>
254254
</div>
255255
<div class="sect1">
256256
<h2 id="_reference_architecture">Reference Architecture</h2>
@@ -810,14 +810,7 @@ <h3 id="_metrics_collection">Metrics Collection</h3>
810810
as defined within the <strong>crunchy-containers</strong> project.</p>
811811
</div>
812812
<div class="paragraph">
813-
<p>The <strong>prometheus push gateway</strong> that is deployed as part of the
814-
<strong>crunchy-metrics</strong> example is a current requirement for the
815-
metrics solution. This will change in an upcoming
816-
release of the <strong>crunchy-containers</strong> project and there will
817-
no longer be a requirement for the push gateway to be deployed.</p>
818-
</div>
819-
<div class="paragraph">
820-
<p>See <a href="https://github.com/CrunchyData/crunchy-containers/blob/master/docs/examples.adoc#metrics-collection">the crunchy-containers Metrics example</a> for more details on setting up the <strong>crunchy-metrics</strong> solution.</p>
813+
<p>See <a href="https://crunchydata.github.io/crunchy-containers/getting-started/kubernetes-and-openshift/#_metrics_and_performance">the crunchy-containers Metrics example</a> for more details on setting up the <strong>crunchy-metrics</strong> solution.</p>
821814
</div>
822815
</div>
823816
<div class="sect2">
@@ -880,7 +873,7 @@ <h3 id="_auto_failover">Auto Failover</h3>
880873
<div class="ulist">
881874
<ul>
882875
<li>
883-
<p>the readiness probe on the primary database container is executed every few seonds to check the <strong>readiness</strong> of the database, this is what tells Kubernetes whether or not the container is <strong>Ready</strong> or <strong>NotReady</strong>.</p>
876+
<p>the readiness probe on the primary database container is executed every few seconds to check the <strong>readiness</strong> of the database, this is what tells Kubernetes whether or not the container is <strong>Ready</strong> or <strong>NotReady</strong>.</p>
884877
</li>
885878
<li>
886879
<p>if a <strong>NotReady</strong> state is detected then that event is caught by the operator which is watching for database containers created by the operator</p>

docs/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@
181181
</div>
182182
</div>
183183
<div class="paragraph">
184-
<p>v3.1, 2018-06-13</p>
184+
<p>v3.1, 2018-06-22</p>
185185
</div>
186186
<div class="sect1">
187187
<h2 id="_documentation">Documentation</h2>

docs/index.json

Lines changed: 11 additions & 11 deletions
Large diffs are not rendered by default.

docs/index.xml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
<pubDate>Thu, 26 Apr 2018 15:22:14 -0700</pubDate>
1818

1919
<guid>https://crunchydata.github.io/postgres-operator/installation/quick-installation/</guid>
20-
<description>Table of Contents Overview Quickstart GKE/PKS Openshift Container Platform Next Steps v3.1, 2018-06-13
20+
<description>Table of Contents Overview Quickstart GKE/PKS Openshift Container Platform Next Steps v3.1, 2018-06-22
2121
Overview There are currently quickstart scripts that seek to automate the deployment to popular Kubernetes environments -
2222
quickstart-for-gke.sh
2323
quickstart-for-ocp.sh
@@ -31,7 +31,7 @@
3131
<pubDate>Thu, 26 Apr 2018 15:22:21 -0700</pubDate>
3232

3333
<guid>https://crunchydata.github.io/postgres-operator/installation/manual-installation/</guid>
34-
<description>Table of Contents Project Structure Installation Prerequsites Basic Installation Create HostPath Directory Build Images &amp;amp; Deploy Makefile Targets Next Steps v3.1, 2018-06-13
34+
<description>Table of Contents Project Structure Installation Prerequsites Basic Installation Create HostPath Directory Build Images &amp;amp; Deploy Makefile Targets Next Steps v3.1, 2018-06-22
3535
Project Structure First, define the following environment variables in .bashrc:
3636
export GOPATH=$HOME/odev export GOBIN=$GOPATH/bin export CO_NAMESPACE=demo export CO_CMD=kubectl export COROOT=$GOPATH/src/github.com/crunchydata/postgres-operator export CO_IMAGE_PREFIX=crunchydata export CO_IMAGE_TAG=centos7-3.1 export CO_BASEOS=centos7 When deploying on Openshift Container Platform, the CO_CMD environment variable should be:
3737
export CO_CMD=oc To perform an installation of the operator, first create the project structure as follows on your host, here we assume a local directory called odev -</description>
@@ -43,7 +43,7 @@
4343
<pubDate>Thu, 26 Apr 2018 15:24:16 -0700</pubDate>
4444

4545
<guid>https://crunchydata.github.io/postgres-operator/installation/helm-chart/</guid>
46-
<description>v3.1, 2018-06-13
46+
<description>v3.1, 2018-06-22
4747
Helm Chart First, pull prebuilt versions from Dockerhub of the postgres-operator containers, specify the image versions, and execute the following Makefile target -
4848
export CO_IMAGE_PREFIX=crunchydata export CO_IMAGE_TAG=centos7-3.1 make pull Then, build and deploy the operator using the provided Helm chart -
4949
cd $COROOT/chart helm install ./postgres-operator helm ls Next Steps Next, visit the Deployment page to deploy the Operator, verify the installation, and view various storage configurations.</description>
@@ -55,7 +55,7 @@
5555
<pubDate>Thu, 26 Apr 2018 15:26:40 -0700</pubDate>
5656

5757
<guid>https://crunchydata.github.io/postgres-operator/installation/deployment/</guid>
58-
<description>Table of Contents Verify Operator Status Configure pgo Client Verify pgo Client Storage Configuration Next Steps v3.1, 2018-06-13
58+
<description>Table of Contents Verify Operator Status Configure pgo Client Verify pgo Client Storage Configuration Next Steps v3.1, 2018-06-22
5959
This document details verifying the installation of the PostgreSQL Operator is successful, in addition to detailing some different storage configurations that can be made.
6060
Verify Operator Status To verify that the operator is deployed and running, run the following:
6161
kubectl get pod --selector=name=postgres-operator You should see output similar to this:</description>
@@ -67,7 +67,7 @@
6767
<pubDate>Tue, 24 Apr 2018 18:26:56 -0700</pubDate>
6868

6969
<guid>https://crunchydata.github.io/postgres-operator/installation/configuration/</guid>
70-
<description>Table of Contents Overview Openshift Container Platform Security Configuration Kube RBAC Basic Authentication Configure TLS pgo RBAC apiserver Configuration postgres-operator Container Configuration bash Completion REST API Deploying pgpool v3.1, 2018-06-13
70+
<description>Table of Contents Overview Openshift Container Platform Security Configuration Kube RBAC Basic Authentication Configure TLS pgo RBAC apiserver Configuration postgres-operator Container Configuration bash Completion REST API Deploying pgpool v3.1, 2018-06-22
7171
Overview This document describes how to configure the operator beyond the default configurations in addition to detailing what the configuration settings mean.
7272
Openshift Container Platform To run the Operator on Openshift Container Platform note the following requirements -</description>
7373
</item>
@@ -78,7 +78,7 @@
7878
<pubDate>Tue, 24 Apr 2018 18:27:30 -0700</pubDate>
7979

8080
<guid>https://crunchydata.github.io/postgres-operator/installation/upgrading-the-operator/</guid>
81-
<description>v3.1, 2018-06-13
81+
<description>v3.1, 2018-06-22
8282
Upgrading from v2.4 to v2.5 For a full list of additions and revisions that occurred in the PostgreSQL Operator v2.5 release, please view the related release page here.
8383
Required Updates This section notes some required steps that will need to be taken in the process of upgrading from v2.4 to v2.5.
8484
Configuration File It will be necessary to update your existing pgo.</description>

docs/installation/configuration/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ <h1>Configuration</h1>
245245
</ul>
246246
</div>
247247
<div class="paragraph">
248-
<p>v3.1, 2018-06-13</p>
248+
<p>v3.1, 2018-06-22</p>
249249
</div>
250250
<div class="sect1">
251251
<h2 id="_overview">Overview</h2>

docs/installation/deployment/index.html

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ <h1>Deployment</h1>
235235
</ul>
236236
</div>
237237
<div class="paragraph">
238-
<p>v3.1, 2018-06-13</p>
238+
<p>v3.1, 2018-06-22</p>
239239
</div>
240240
<div class="paragraph">
241241
<p>This document details verifying the installation of the PostgreSQL Operator
@@ -336,6 +336,39 @@ <h2 id="_configure_strong_pgo_strong_client">Configure <strong>pgo</strong> Clie
336336
</div>
337337
</div>
338338
<div class="paragraph">
339+
<p>Roles are defined in a file called <strong>pgorole</strong>. This file defines each role and the
340+
permissions for that role. By default, two roles are defined as samples -</p>
341+
</div>
342+
<div class="literalblock">
343+
<div class="content">
344+
<pre>pgoadmin
345+
pgoreader</pre>
346+
</div>
347+
</div>
348+
<div class="paragraph">
349+
<p>This file, moved to your $HOME folder, is optional. These default settings can be adjusted to meet local
350+
security requirements.</p>
351+
</div>
352+
<div class="paragraph">
353+
<p>The format of this file is as follows -</p>
354+
</div>
355+
<div class="literalblock">
356+
<div class="content">
357+
<pre>rolename: permissionA, permissionB</pre>
358+
</div>
359+
</div>
360+
<div class="paragraph">
361+
<p>These are defined in the following file -</p>
362+
</div>
363+
<div class="literalblock">
364+
<div class="content">
365+
<pre>$COROOT/conf/apiserver/pgorole</pre>
366+
</div>
367+
</div>
368+
<div class="paragraph">
369+
<p>The complete set of permissions is documented in the <a href="https://crunchydata.github.io/postgres-operator/installation/configuration/">Configuration</a> document.</p>
370+
</div>
371+
<div class="paragraph">
339372
<p>The <strong>pgo</strong> client needs the URL to connect to the operator.</p>
340373
</div>
341374
<div class="paragraph">

0 commit comments

Comments
 (0)