For development purpose seems you don't need to ssh into vagrant,
I am having this setting in my docker-compose.yml :
dl_db:
image: mysql:5.7
ports: - 3306:3306
environment:
- MYSQL_ROOT_PASSWORD=root
- MYSQL_DATABASE=oemjih
restart: always
Put this line in your vagrantfile
config.vm.network :forwarded_port, guest: 3306, host: 3306
and from your sqlyog panel just accessing the db via tcp/ip with port:3306 as mapped in as host port in vagrantfile without ssh :
MySql Host Address: localhost
username : root
password : root
port : 3306