Difference between revisions of "Pgo"
(17 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
+ | https://access.crunchydata.com/documentation/postgres-operator/v5/quickstart/ | ||
+ | |||
+ | https://access.crunchydata.com/documentation/postgres-operator/v5/ | ||
+ | |||
+ | https://access.crunchydata.com/documentation/postgres-operator/v5/faq/ | ||
+ | |||
+ | https://github.com/CrunchyData/postgres-operator | ||
+ | |||
+ | https://github.com/CrunchyData/postgres-operator-client/releases | ||
+ | |||
+ | https://github.com/CrunchyData/postgres-operator/releases # pgo client | ||
+ | |||
+ | https://access.crunchydata.com/documentation/postgres-operator/4.7.0/tutorial/tls/ | ||
+ | |||
+ | |||
+ | # Install | ||
+ | |||
+ | - https://access.crunchydata.com/documentation/postgres-operator/v5/quickstart/ | ||
+ | = https://blog.crunchydata.com/blog/getting-started-with-pgo-postgres-operator-5.0 | ||
+ | |||
+ | |||
+ | ``` | ||
+ | git clone https://github.com/CrunchyData/postgres-operator.git | ||
+ | cd postgres-operator/ | ||
+ | git checkout REL_4_6 | ||
+ | cd installers/kubectl | ||
+ | kubectl create namespace pgo | ||
+ | kubectl apply -f postgres-operator.yml | ||
+ | kubectl get pods -n pgo | ||
+ | ./client-setup.sh | ||
+ | ``` | ||
+ | |||
+ | .bashrc | ||
+ | ``` | ||
+ | export PGOUSER="$HOME/.pgo/pgo/pgouser" | ||
+ | export PGO_CA_CERT="$HOME/.pgo/pgo/client.crt" | ||
+ | export PGO_CLIENT_CERT="$HOME/.pgo/pgo/client.crt" | ||
+ | export PGO_CLIENT_KEY="$HOME/.pgo/pgo/client.key" | ||
+ | export PGO_APISERVER_URL='https://127.0.0.1:8443' | ||
+ | export PGO_NAMESPACE=pgo | ||
+ | ``` | ||
+ | |||
+ | ``` | ||
+ | grep "export PATH" ~/.bashrc && echo PATH update exists || echo export PATH="$HOME/.pgo/pgo:$PATH" >> ~/.bashrc | ||
+ | . ~/.bashrc | ||
+ | pgo | ||
+ | # ~/.pgo/pgo/pgo show | ||
+ | ``` | ||
+ | |||
- https://access.crunchydata.com/documentation/postgres-operator/latest/architecture/high-availability/ | - https://access.crunchydata.com/documentation/postgres-operator/latest/architecture/high-availability/ | ||
- https://access.crunchydata.com/documentation/postgres-operator/4.1.1/operatorcli/cli/pgo_create_user/ | - https://access.crunchydata.com/documentation/postgres-operator/4.1.1/operatorcli/cli/pgo_create_user/ | ||
+ | - https://access.crunchydata.com/documentation/postgres-operator/4.6.2/tutorial/tls/ | ||
# Install client | # Install client | ||
Line 13: | Line 63: | ||
pgo create pgadmin -n pgo hostcmd | pgo create pgadmin -n pgo hostcmd | ||
+ | ``` | ||
+ | |||
+ | |||
+ | |||
+ | https://access.crunchydata.com/documentation/postgres-operator/latest/quickstart/ | ||
+ | |||
+ | https://access.crunchydata.com/documentation/postgres-operator/latest/ | ||
+ | |||
+ | https://access.crunchydata.com/documentation/postgres-operator/4.6.2/architecture/high-availability/ | ||
+ | |||
+ | https://www.crunchydata.com/developers/download-postgres/containers/postgres-operator | ||
+ | |||
+ | Expose api | ||
+ | ``` | ||
+ | microk8s.kubectl port-forward -n pgo svc/postgres-operator 8443:8443 | ||
+ | ``` | ||
+ | |||
+ | Run some commands | ||
+ | ``` | ||
+ | pgo create cluster hippo | ||
+ | pgo show cluster -n pgo --all | ||
+ | pgo show user hippo --show-system-accounts | ||
+ | ``` | ||
+ | |||
+ | ``` | ||
+ | pgo create cluster hacluster --replica-count=2 --pod-anti-affinity=preferred --pgbouncer | ||
``` | ``` |
Latest revision as of 02:35, 24 March 2023
https://access.crunchydata.com/documentation/postgres-operator/v5/quickstart/
https://access.crunchydata.com/documentation/postgres-operator/v5/
https://access.crunchydata.com/documentation/postgres-operator/v5/faq/
https://github.com/CrunchyData/postgres-operator
https://github.com/CrunchyData/postgres-operator-client/releases
https://github.com/CrunchyData/postgres-operator/releases # pgo client
https://access.crunchydata.com/documentation/postgres-operator/4.7.0/tutorial/tls/
Install
- https://access.crunchydata.com/documentation/postgres-operator/v5/quickstart/ = https://blog.crunchydata.com/blog/getting-started-with-pgo-postgres-operator-5.0
git clone https://github.com/CrunchyData/postgres-operator.git cd postgres-operator/ git checkout REL_4_6 cd installers/kubectl kubectl create namespace pgo kubectl apply -f postgres-operator.yml kubectl get pods -n pgo ./client-setup.sh
.bashrc
export PGOUSER="$HOME/.pgo/pgo/pgouser" export PGO_CA_CERT="$HOME/.pgo/pgo/client.crt" export PGO_CLIENT_CERT="$HOME/.pgo/pgo/client.crt" export PGO_CLIENT_KEY="$HOME/.pgo/pgo/client.key" export PGO_APISERVER_URL='https://127.0.0.1:8443' export PGO_NAMESPACE=pgo
grep "export PATH" ~/.bashrc && echo PATH update exists || echo export PATH="$HOME/.pgo/pgo:$PATH" >> ~/.bashrc . ~/.bashrc pgo # ~/.pgo/pgo/pgo show
- https://access.crunchydata.com/documentation/postgres-operator/latest/architecture/high-availability/
- https://access.crunchydata.com/documentation/postgres-operator/4.1.1/operatorcli/cli/pgo_create_user/
- https://access.crunchydata.com/documentation/postgres-operator/4.6.2/tutorial/tls/
Install client
https://github.com/jeremybusk/k8s-zabbix-deploy/blob/main/pgo/install-pgo.sh
kubectl -n pgo port-forward svc/postgres-operator 8443:8443 pgo create cluster hostcmd --service-type=NodePort --replica-count=2 --pod-anti-affinity=required psql -h kub1 -U testuser -p 317xx -d postgres pgo create pgadmin -n pgo hostcmd
https://access.crunchydata.com/documentation/postgres-operator/latest/quickstart/
https://access.crunchydata.com/documentation/postgres-operator/latest/
https://access.crunchydata.com/documentation/postgres-operator/4.6.2/architecture/high-availability/
https://www.crunchydata.com/developers/download-postgres/containers/postgres-operator
Expose api
microk8s.kubectl port-forward -n pgo svc/postgres-operator 8443:8443
Run some commands
pgo create cluster hippo pgo show cluster -n pgo --all pgo show user hippo --show-system-accounts
pgo create cluster hacluster --replica-count=2 --pod-anti-affinity=preferred --pgbouncer