502 Bad Gateway after clean install

  • just made a clean install of CentOS 8, docker, docker-compose, git and devilbox
  • my local user is “kai” and it belongs to the “docker” group
  • devilbox is cloned into /home/kai/
  • the .env file has been edited correctly
  • “docker-compose up httpd php” starts without complains
  • !!! THE PROBLEM: http://localhost returns: 502 Bad Gateway nginx/1.16.1
  • nano defaultlocalhost-error.log: "connect() failed (113: No route to host) while connecting to upstream, client: 172.16.238.1, server: _, request: “GET / HTTP/1.1”, upstream: “fastcgi://172.16.238.10:9000”, host: “localhost”

I am a total newbee to Linux, docker, networking … (everything then;-) - but I have followed all installation instructions by the letter and no error occurred - what could be wrong?
What information should I still provide here?

Thanks,
Kai

If you could post your .env file.

Thanks - here it is:

DEBUG_COMPOSE_ENTRYPOINT=2
DOCKER_LOGS=0
DEVILBOX_PATH=.
LOCAL_LISTEN_ADDR=
TLD_SUFFIX=loc
EXTRA_HOSTS=
NEW_UID=1000
NEW_GID=1001
TIMEZONE=UTC
DNS_CHECK_TIMEOUT=1
DEVILBOX_UI_SSL_CN=localhost,*.localhost,devilbox,*.devilbox,httpd
DEVILBOX_UI_PROTECT=0
DEVILBOX_UI_PASSWORD=password
DEVILBOX_UI_ENABLE=1
DEVILBOX_VENDOR_PHPMYADMIN_AUTOLOGIN=1
DEVILBOX_VENDOR_PHPPGADMIN_AUTOLOGIN=1
PHP_SERVER=7.3
HTTPD_SERVER=nginx-stable
MYSQL_SERVER=mariadb-10.3
PGSQL_SERVER=12.1
REDIS_SERVER=5.0
MEMCD_SERVER=1.5
MONGO_SERVER=4.2
MOUNT_OPTIONS=,z
HOST_PATH_HTTPD_DATADIR=./data/www
HOST_PATH_SSH_DIR=~/.ssh
PHP_MODULES_ENABLE=
PHP_MODULES_DISABLE=oci8,PDO_OCI,pdo_sqlsrv,sqlsrv,rdkafka,swoole
PHP_MAIL_CATCH_ALL=2
HOST_PORT_HTTPD=80
HOST_PORT_HTTPD_SSL=443
HTTPD_VHOST_SSL_TYPE=both
HTTPD_DOCROOT_DIR=htdocs
HTTPD_TEMPLATE_DIR=.devilbox
HTTPD_TIMEOUT_TO_PHP_FPM=180
HTTPD_NGINX_WORKER_PROCESSES=auto
HTTPD_NGINX_WORKER_CONNECTIONS=1024
MYSQL_ROOT_PASSWORD=
HOST_PORT_MYSQL=3306
PGSQL_ROOT_USER=postgres
PGSQL_ROOT_PASSWORD=
PGSQL_HOST_AUTH_METHOD=trust
HOST_PORT_PGSQL=5432
HOST_PORT_REDIS=6379
REDIS_ARGS=
HOST_PORT_MEMCD=11211
HOST_PORT_MONGO=27017
HOST_PORT_BIND=1053
BIND_DNS_RESOLVER=8.8.8.8,8.8.4.4
BIND_DNSSEC_VALIDATE=no
BIND_TTL_TIME=
BIND_REFRESH_TIME=
BIND_RETRY_TIME=
BIND_EXPIRY_TIME=
BIND_MAX_CACHE_TIME=
BIND_LOG_DNS_QUERIES=0

After almost tearingmy hair out, I found this thread:
https://github.com/cytopia/devilbox/issues/697

Basically, this errors comes up if you use the new Docker CLI
docker compose up

If you use the older one (only god knows why) it works!
docker-compose up

Hope this helps anyone