Last active
March 31, 2022 09:02
-
-
Save oshinko/63128c884dc6544099b82fffbc63f282 to your computer and use it in GitHub Desktop.
Run the MySQL sandbox container
This file contains hidden or 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
| docker run --rm -it mysql mysql -h host.docker.internal -u root -p --default-character-set=utf8 test |
This file contains hidden or 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
| docker exec -it sandbox mysql -u root -p --default-character-set=utf8 test |
This file contains hidden or 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
| docker run ^ | |
| --rm ^ | |
| -e MYSQL_ROOT_PASSWORD=root ^ | |
| -e MYSQL_DATABASE=test ^ | |
| -p 3306:3306 ^ | |
| --name sandbox ^ | |
| mysql:latest ^ | |
| mysqld ^ | |
| --character-set-server=utf8mb4 ^ | |
| --collation-server=utf8mb4_unicode_ci |
This file contains hidden or 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
| docker run \ | |
| --rm \ | |
| -e MYSQL_ROOT_PASSWORD=root \ | |
| -e MYSQL_DATABASE=test \ | |
| -p 3306:3306 \ | |
| --name sandbox \ | |
| mysql:latest \ | |
| mysqld \ | |
| --character-set-server=utf8mb4 \ | |
| --collation-server=utf8mb4_unicode_ci |
This file contains hidden or 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
| docker stop sandbox |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment