Skip to content

Commit

Permalink
k8s example: Update instructions to use proxy service name
Browse files Browse the repository at this point in the history
Use service name instead of querying the service to get its IP
to connect to the database
  • Loading branch information
Miyurz committed Dec 9, 2019
1 parent 59e4880 commit 97e2a01
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions examples/kubernetes/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,20 +105,12 @@ kubectl create -f stolon-proxy-service.yaml

### Connect to the db

#### Get the proxy service ip

```
kubectl get svc
NAME LABELS SELECTOR IP(S) PORT(S)
stolon-proxy-service <none> stolon-cluster=kube-stolon,stolon-proxy=true 10.247.50.217 5432/TCP
```

#### Connect to the proxy service

The password for the stolon user will be the value specified in your `secret.yaml` above (or `password1` if you did not change it).

```
psql --host 10.247.50.217 --port 5432 postgres -U stolon -W
psql --host stolon-proxy-service --port 5432 postgres -U stolon -W
Password for user stolon:
psql (9.4.5, server 9.4.4)
Type "help" for help.
Expand Down

0 comments on commit 97e2a01

Please sign in to comment.