mirror of
https://github.com/fleetdm/fleet
synced 2026-04-21 21:47:20 +00:00
**Related issue:** Resolves #35937 Changes: - Fix `make db-replica-setup` - mention the tool in `docs/contributing/getting-started/testing-and-local-development.md`.
29 lines
646 B
Markdown
29 lines
646 B
Markdown
# MySQL Replica Testing
|
|
|
|
This directory contains scripts to run/test a local Fleet instance with a MySQL Read Replica.
|
|
|
|
## Run MySQL Main and Read Replica Docker Images
|
|
|
|
> Run all commands from fleet's root repository directory.
|
|
>
|
|
>The regular `docker compose up` command should be running for the other services to work.
|
|
|
|
```sh
|
|
docker compose -f ./tools/mysql-replica-testing/docker-compose.yml up
|
|
```
|
|
|
|
## Configure MySQL Main and Read Replica
|
|
|
|
```sh
|
|
# Configure the main and read replica for replication.
|
|
make db-replica-setup
|
|
|
|
# Reset the main database.
|
|
make db-replica-reset
|
|
```
|
|
|
|
## Run Fleet with Read Replica
|
|
|
|
```sh
|
|
make db-replica-run
|
|
```
|