Created
December 2, 2024 07:21
-
-
Save Mike-Schvedov/338caf12603a1540151828c8a48e1310 to your computer and use it in GitHub Desktop.
MySQL Container Configuration
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 -d \ | |
--name mysql-container \ | |
--restart unless-stopped \ | |
-e MYSQL_ROOT_PASSWORD=rootpassword \ | |
-e MYSQL_DATABASE=mydatabase \ | |
-e MYSQL_USER=myuser \ | |
-e MYSQL_PASSWORD=mypassword \ | |
-v mysql-data:/var/lib/mysql \ | |
-p 3306:3306 \ | |
mysql:latest |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment