Skip to content

Instantly share code, notes, and snippets.

@hyrmn
Created October 26, 2021 01:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hyrmn/bb56cc927738dd9b4c60fe6fab9ec8ea to your computer and use it in GitHub Desktop.
Save hyrmn/bb56cc927738dd9b4c60fe6fab9ec8ea to your computer and use it in GitHub Desktop.
go to docker.com and create an account. download the appropriate docker desktop installer for your computer and install
Then you will need to create a file called docker-compose.yml in some directory on your hard drive
version: '3.8'
services:
db:
image: mysql
command: --default-authentication-plugin=mysql_native_password
restart: always
environment:
MYSQL_ROOT_PASSWORD: TomIsKool
networks:
- localhost_network
volumes:
- ./mysql:/var/lib/mysql
adminer:
image: adminer
restart: always
networks:
- localhost_network
depends_on:
- db
ports:
- 8080:8080
mysql-workbench:
image: lscr.io/linuxserver/mysql-workbench
container_name: mysql-workbench
environment:
- PUID=1000
- PGID=1000
- TZ=Europe/London
volumes:
- ./workbench:/config
depends_on:
- db
ports:
- 3000:3000
cap_add:
- IPC_LOCK
restart: unless-stopped
networks:
localhost_network:
driver: bridge
volumes:
mysql:
workbench:
from your command prompt, you can go to where you created `docker-compose.yml` with the contents above and run `docker-compose up`.
That will bring up all of the services in the docker-compose file. You can then navigate to localhost:3000 to connect to
mysql workbench.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment