0

We are using docker-compose in our app and am not familiar with this part of the application we are getting this error after runnning docker-compose up --build:

Mysql: forward host lookup failed: Unknown host
Shadow
  • 33,525
  • 10
  • 51
  • 64
CommonSenseCode
  • 23,522
  • 33
  • 131
  • 186

1 Answers1

5

After an inspection to hosts list created by docker-compose:

$ docker network prune
$ docker network ls
$ docker network inspect <desired_network>

I noticed db was not there, so I tried to build it up and see what happens:

$ docker-compose run <desired_db_image>

Getting the correct output:

Initializing database

mkdir: cannot create directory '/var/lib/mysql//mysql': No space left on device

Fatal error Can't create database directory '/var/lib/mysql//mysql'

So you need to free some space:

$ docker system prune

Select: y

Community
  • 1
  • 1
G. I. Joe
  • 1,585
  • 17
  • 21