Skip to content

Commit

Permalink
Fix example YAMLs (#569)
Browse files Browse the repository at this point in the history
Signed-off-by: Tamal Saha <[email protected]>
  • Loading branch information
tamalsaha authored Oct 13, 2023
1 parent 3a033fe commit 1c4a4d8
Show file tree
Hide file tree
Showing 44 changed files with 7 additions and 133 deletions.
2 changes: 0 additions & 2 deletions docs/examples/pgbouncer/custom-version/pgbouncer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ spec:
connectionPool:
port: 2580
reservePoolSize: 5
userListSecretRef:
name: db-user-pass
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,5 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
- admin1
userListSecretRef:
name: db-user-pass
monitor:
agent: prometheus.io/builtin
5 changes: 0 additions & 5 deletions docs/examples/pgbouncer/monitoring/coreos-prom-pgbouncer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,6 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
- admin1
userListSecretRef:
name: db-user-pass
monitor:
agent: prometheus.io/operator
prometheus:
Expand Down
5 changes: 0 additions & 5 deletions docs/examples/pgbouncer/pb-overview.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,6 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
- admin1
userListSecretRef:
name: db-user-pass
monitor:
agent: prometheus.io/operator
prometheus:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
userListSecretRef:
name: db-user-pass
podTemplate:
spec:
imagePullSecrets:
Expand Down
5 changes: 0 additions & 5 deletions docs/examples/pgbouncer/quickstart/pgbouncer-server-mod.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,4 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
- admin1
userListSecretRef:
name: db-user-pass
terminationPolicy: WipeOut
5 changes: 0 additions & 5 deletions docs/examples/pgbouncer/quickstart/pgbouncer-server.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,4 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
- admin1
userListSecretRef:
name: db-user-pass
terminationPolicy: WipeOut
1 change: 0 additions & 1 deletion docs/examples/proxysql/builtin-prom-proxysql.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 1
mode: GroupReplication
backend:
name: my-group
monitor:
Expand Down
1 change: 0 additions & 1 deletion docs/examples/proxysql/coreos-prom-proxysql.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 1
mode: GroupReplication
backend:
name: my-group
monitor:
Expand Down
1 change: 0 additions & 1 deletion docs/examples/proxysql/custom-proxysql.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 1
mode: GroupReplication
backend:
name: my-group
configSecret:
Expand Down
1 change: 0 additions & 1 deletion docs/examples/proxysql/demo-proxy-my-group.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 1
mode: GroupReplication
backend:
name: mysql-server
terminationPolicy: WipeOut
1 change: 0 additions & 1 deletion docs/examples/proxysql/proxysql-private-registry.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 1
mode: GroupReplication
backend:
name: my-group
podTemplate:
Expand Down
2 changes: 2 additions & 0 deletions docs/guides/kafka/concepts/catalog.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ spec:
podSecurityPolicies:
databasePolicyName: kafka-db
version: 3.4.0
cruiseControl:
image: ghcr.io/kubedb/cruise-control:3.4.0
```
### metadata.name
Expand Down
5 changes: 0 additions & 5 deletions docs/guides/pgbouncer/cli/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,6 @@ metadata:
uid: 158b7c58-ecb2-4a77-bceb-081489b4921a
spec:
connectionPool:
adminUsers:
- admin
- admin1
poolMode: session
port: 5432
reservePoolSize: 5
Expand All @@ -105,8 +102,6 @@ spec:
spec:
resources: {}
replicas: 1
userListSecretRef:
name: db-user-pass
version: 1.17.0
status:
observedGeneration: 1$6208915667192219204
Expand Down
12 changes: 0 additions & 12 deletions docs/guides/pgbouncer/concepts/pgbouncer.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ spec:
databaseRef:
name: "quick-postgres"
namespace: demo
authSecretRef:
name: "one-specific-user"
- alias: "tmpdb"
databaseName: "mydb"
databaseRef:
Expand All @@ -51,10 +49,6 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
userListSecretRef:
name: db-user-pass
monitor:
agent: prometheus.io/operator
prometheus:
Expand Down Expand Up @@ -156,12 +150,6 @@ ConnectionPool is used to configure pgbouncer connection-pool. All the fields he

- `spec.connectionPool.IgnoreStartupParameters`: specifies comma-separated startup parameters that pgbouncer knows are handled by admin and it can ignore them.

### spec.userListSecretRef:

UserList field is used to specify a secret that contains the list of authorised users along with their passwords. Basically this secret is created from the standard pgbouncer userlist file.

- `spec.userList.userListSecretRef.name`: specifies the name of the secret containing userlist. Has to be created in the same namespace as the PgBouncer crd.

### spec.monitor

PgBouncer managed by KubeDB can be monitored with builtin-Prometheus and Prometheus operator out-of-the-box. To learn more,
Expand Down
5 changes: 0 additions & 5 deletions docs/guides/pgbouncer/custom-versions/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,6 @@ spec:
version: "1.17.0"
replicas: 1
connectionPool:
adminUsers:
- admin
- admin1
poolMode: session
port: 5432
reservePoolSize: 5
Expand All @@ -74,6 +71,4 @@ spec:
databaseRef:
name: quick-postgres
namespace: demo
userListSecretRef:
name: db-user-pass
```
5 changes: 0 additions & 5 deletions docs/guides/pgbouncer/monitoring/using-builtin-prometheus.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,6 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
- admin1
userListSecretRef:
name: db-user-pass
monitor:
agent: prometheus.io/builtin
```
Expand Down
5 changes: 0 additions & 5 deletions docs/guides/pgbouncer/monitoring/using-prometheus-operator.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,11 +122,6 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
- admin1
userListSecretRef:
name: db-user-pass
monitor:
agent: prometheus.io/operator
prometheus:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,10 +122,6 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
userListSecretRef:
name: db-user-pass
podTemplate:
spec:
imagePullSecrets:
Expand Down
34 changes: 0 additions & 34 deletions docs/guides/pgbouncer/quickstart/quickstart.md
Original file line number Diff line number Diff line change
Expand Up @@ -174,11 +174,6 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
- admin1
userListSecretRef:
name: db-user-pass
terminationPolicy: Delete
```

Expand All @@ -188,7 +183,6 @@ Here,
- `spec.replicas` specifies the number of replica pgbouncer server pods to be created for the PgBouncer object.
- `spec.databases` specifies the databases that are going to be served via PgBouncer.
- `spec.connectionPool` specifies the configurations for connection pool.
- `spec.userListSecretRef` specifies the secret that contains the standard pgbouncer `userlist` file.
- `spec.terminationPolicy` specifies what policy to apply while deletion.

### spec.databases
Expand Down Expand Up @@ -217,29 +211,6 @@ ConnectionPool is used to configure pgbouncer connection pool. All the fields he
- `spec.connectionPool.maxDbConnections`: specifies the value of max_db_connections.
- `spec.connectionPool.maxUserConnections`: specifies the value of max_user_connections.

### spec.userListSecretRef

UserList field is used to specify a secret that contains the list of authorized users along with their passwords. Basically this secret is created from the standard pgbouncer userlist file.

- `spec.userListSecretRef.name`: specifies the name of the secret containing userlist in the same namespace as the PgBouncer crd.

In this tutorial we will use a standard userlist text file to create a secret for spec.userListSecretRef. In the userlist text file we have added `pgbouncer` as user and `ZFopeLnwkSf_f5Ys` as corresponding password. The file looks like this:

```
"postgres" "ZFopeLnwkSf_f5Ys"
"myuser" "mypass"
```

We will need user `myuser` with password `mypass` later in this tutorial.

```bash
$ wget https://raw.githubusercontent.com/kubedb/docs/{{< param "info.version" >}}/docs/examples/pgbouncer/quickstart/userlist
2022-06-01 12:29:02 (1.02 MB/s) - ‘userlist’ saved [47/47]
$ kubectl create secret generic -n demo db-user-pass --from-file=./userlist.txt
secret/db-user-pass created
```
### spec.terminationPolicy

`terminationPolicy` gives flexibility whether to `nullify`(reject) the delete operation of `PgBouncer` crd or which resources KubeDB should keep or delete when you delete `PgBouncer` crd. KubeDB provides following four termination policies:
Expand Down Expand Up @@ -354,11 +325,6 @@ spec:
connectionPool:
maxClientConnections: 20
reservePoolSize: 5
adminUsers:
- admin
- admin1
userListSecretRef:
name: db-user-pass
terminationPolicy: Delete
```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-server
syncUsers: true
Expand Down
1 change: 0 additions & 1 deletion docs/guides/proxysql/autoscaler/compute/cluster/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-server
syncUsers: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@ metadata:
name: proxy-server
namespace: demo
spec:
version: "2.3.2-debian"
version: "2.3.2-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-server
terminationPolicy: WipeOut
1 change: 0 additions & 1 deletion docs/guides/proxysql/clustering/proxysql-cluster/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-server
terminationPolicy: WipeOut
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-server
initConfig:
Expand Down
1 change: 0 additions & 1 deletion docs/guides/proxysql/concepts/proxysql/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 1
mode: GroupReplication
backend:
name: my-group
authSecret:
Expand Down
1 change: 0 additions & 1 deletion docs/guides/proxysql/custom-rbac/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,6 @@ metadata:
spec:
version: "2.4.4-debian"
replicas: 1
mode: Galera
backend:
name: xtradb-galera-appbinding
syncUsers: true
Expand Down
1 change: 0 additions & 1 deletion docs/guides/proxysql/custom-rbac/yamls/my-custom-db.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.4.4-debian"
replicas: 1
mode: Galera
backend:
name: xtradb-galera-appbinding
syncUsers: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.4.4-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-grp
syncUsers: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ metadata:
spec:
version: "2.4.4-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-grp
syncUsers: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.4.4-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-grp
syncUsers: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,6 @@ metadata:
spec:
version: "2.4.4-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-grp
syncUsers: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ metadata:
spec:
version: "2.3.2-debian"
replicas: 3
mode: GroupReplication
backend:
name: mysql-server
syncUsers: true
Expand Down
Loading

0 comments on commit 1c4a4d8

Please sign in to comment.