Last active
April 16, 2021 09:24
-
-
Save tomoyk/e984589d99711347fd47fd57af6e90db to your computer and use it in GitHub Desktop.
phpmyadminとmysqlの環境を作るやつ
This file contains 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
version: '3' | |
services: | |
db: | |
container_name: composed-mysql | |
image: mysql:5.7 | |
volumes: | |
- db_data:/var/lib/mysql | |
restart: always | |
environment: | |
MYSQL_ROOT_PASSWORD: foobar123 | |
MYSQL_DATABASE: db_study | |
pma: | |
container_name: composed-pma | |
image: phpmyadmin/phpmyadmin | |
ports: | |
- "8080:80" | |
restart: always | |
environment: | |
PMA_HOST: db | |
PMA_USER: root | |
PMA_PASSWORD: foobar123 | |
volumes: | |
db_data: |
ブラウザから http://localhost:8080/
へアクセス!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
使い方
NOTE
以下のエラーが出るとき:
古いイメージが残っているので以下を実行