forked from lesovsky/pgscv
-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: Mikhail Grigorev <[email protected]>
- Loading branch information
Showing
32 changed files
with
26,286 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# pgSCV settings | ||
LOG_LEVEL=debug | ||
#PGSCV_CONFIG_FILE=/etc/pgscv.yaml | ||
#PGSCV_LISTEN_ADDRESS="127.0.0.1:9890" | ||
#PGSCV_AUTH_USERNAME=monitoring | ||
#PGSCV_AUTH_PASSWORD=supersecretpassword | ||
#PGSCV_AUTH_KEYFILE=/etc/ssl/private/ssl-cert-snakeoil.key | ||
#PGSCV_AUTH_CERTFILE=/etc/ssl/certs/ssl-cert-snakeoil.pem | ||
#PGSCV_NO_TRACK_MODE=false | ||
#PGSCV_COLLECT_TOP_QUERY=15 | ||
#PGSCV_COLLECT_TOP_TABLE=15 | ||
#PGSCV_COLLECT_TOP_INDEX=15 | ||
#POSTGRES_DSN_db1=postgresql://pgscv:pgscv@host1:5432/pgbench1 | ||
#POSTGRES_DSN_db2=postgresql://pgscv:pgscv@host1:5432/pgbench2 | ||
#PGSCV_DATABASES="^pgbench.*$" | ||
#PGSCV_DISABLE_COLLECTORS="system,postgres/logs" | ||
|
||
# Patroni settings | ||
PATRONI_RESTAPI_USERNAME=admin | ||
PATRONI_RESTAPI_PASSWORD=admin | ||
PATRONI_SUPERUSER_USERNAME=postgres | ||
PATRONI_SUPERUSER_PASSWORD=postgres | ||
PATRONI_REPLICATION_USERNAME=replicator | ||
PATRONI_REPLICATION_PASSWORD=replicate | ||
PATRONI_admin_PASSWORD=admin | ||
PATRONI_admin_OPTIONS=createdb,createrole |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
# pgSCV demo laboratory | ||
|
||
### Requirements | ||
|
||
- Docker | ||
- Docker Compose | ||
|
||
### List of running containers and ports | ||
- pgscv (listen port: 9890) | ||
- grafana (listen port: 3000) | ||
- vmagent (listen port: 8429) | ||
- victoriametrics (listen port: 8428) | ||
- postgres12 (listen port: 5432) | ||
- postgres13 (listen port: 5433) | ||
- postgres14 (listen port: 5434) | ||
- postgres15 (listen port: 5435) | ||
- postgres16 (listen port: 5436) | ||
- pgbouncer12 (listen port: 6432) | ||
- pgbouncer13 (listen port: 6433) | ||
- pgbouncer14 (listen port: 6434) | ||
- pgbouncer15 (listen port: 6435) | ||
- pgbouncer16 (listen port: 6436) | ||
- etcd1 | ||
- etcd2 | ||
- etcd3 | ||
- patroni1 (listen port: 5437, 8008) | ||
- patroni2 (listen port: 5438, 8009) | ||
- patroni3 (listen port: 5439, 8010) | ||
- haproxy (listen port: 5000, 5001) | ||
- pgbench_12 | ||
- pgbench_13 | ||
- pgbench_14 | ||
- pgbench_15 | ||
- pgbench_16 | ||
- pgbench_patroni | ||
- pgbench_patroni_s | ||
|
||
### Quick start | ||
|
||
Run pgSCV demo laboratory: | ||
```bash | ||
docker-compose up -d | ||
``` | ||
|
||
Start pgbench tests: | ||
```bash | ||
./start_pgbench.sh | ||
``` | ||
|
||
Open Grafana into Web browser URL: http://127.0.0.1:3000 | ||
|
||
Login: admin | ||
|
||
Password: admin | ||
|
||
Open pgSCV dashboards, enjoy and drink coffee ;) | ||
|
||
View pgSCV logs: | ||
```bash | ||
docker logs pgscv -f | ||
``` | ||
|
||
### Stop demo laboratory and cleanup data | ||
|
||
Stop pgbench tests: | ||
```bash | ||
./stop_pgbench.sh | ||
``` | ||
|
||
Stop pgSCV demo laboratory and cleanup demo data: | ||
```bash | ||
./stop_and_cleanup_data.sh | ||
``` |
Oops, something went wrong.