Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/vasansr/docker-ubuntu-mysql
Source for creating ubunty-mysql docker image.
https://github.com/vasansr/docker-ubuntu-mysql
Last synced: 2 months ago
JSON representation
Source for creating ubunty-mysql docker image.
- Host: GitHub
- URL: https://github.com/vasansr/docker-ubuntu-mysql
- Owner: vasansr
- Created: 2014-09-29T13:13:56.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2014-10-01T12:01:39.000Z (about 10 years ago)
- Last Synced: 2024-03-21T16:31:46.203Z (9 months ago)
- Language: Shell
- Size: 125 KB
- Stars: 9
- Watchers: 2
- Forks: 7
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
#docker-ubuntu-mysql
Dedicated mysql container, intended for exposure to another container.
## AboutThis mysql container is based on ubuntu:trusty, and has the following in addition:
* mysql-server
* Listens on 0.0.0.0 instead of the default 127.0.0.1
* Port 3306 is exposed, in case you are not linking containers
* Allows for a root password to be set when run for the first time## Example
### Running
Simple, not exposed:
```shell
docker run -d --name="mysql-run" \
-e "MYSQL_PASSWORD=password" \
vasansr/ubuntu-mysql
```Exposed:
```shell
docker run -d --name="mysql-run" \
-e "MYSQL_PASSWORD=password" \
-p 3306:3306 \
vasansr/ubuntu-mysql
```Explanation:
* -d : Run daemonized
* --name : The name of the container
* -e MYSQL_PASSWORD : To set the root password for connecting from other containers/hosts. Change password to the password that you want to set. Use a strong password if you are exposing the container using -p
* -p : expose port 3306 as port 3306 on the host
* vasansr/ubuntu-mysql : The name of the repository