Skip to content

Commit

Permalink
Use tmpfs to mount MySQL data.
Browse files Browse the repository at this point in the history
This approach to speed up database tests was suggested by https://www.fusonic.net/en/blog/fusonic-test-with-databases-part-3.

Signed-off-by: Bradley Grainger <[email protected]>
  • Loading branch information
bgrainger committed Jul 16, 2022
1 parent 2f80198 commit d5e1c64
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions .ci/docker-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ docker run -d \
-p $PORT:3306 \
--name mysql \
-e MYSQL_ROOT_PASSWORD='test' \
--tmpfs /var/lib/mysql \
$IMAGE \
--log-bin-trust-function-creators=1 \
--local-infile=1 \
Expand Down
2 changes: 1 addition & 1 deletion tests/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ with Connector/NET and that [known bugs have been fixed](https://mysqlconnector.

The tests require a MySQL server. The simplest way to run one is with [Docker](https://www.docker.com/community-edition):

docker run -d --rm --name mysqlconnector -e MYSQL_ROOT_PASSWORD=pass -p 3306:3306 mysql:8.0.27 --max-allowed-packet=96M --character-set-server=utf8mb4 --log-bin-trust-function-creators=1 --local-infile=1 --max-connections=250
docker run -d --rm --name mysqlconnector -e MYSQL_ROOT_PASSWORD=pass -p 3306:3306 --tmpfs /var/lib/mysql mysql:8.0 --max-allowed-packet=96M --character-set-server=utf8mb4 --log-bin-trust-function-creators=1 --local-infile=1 --max-connections=250

Copy the file `SideBySide/config.json.example` to `SideBySide/config.json`, then edit
the `config.json` file in order to connect to your server. If you are using the Docker
Expand Down

0 comments on commit d5e1c64

Please sign in to comment.