Password protected Intranet is not working without redis

When I set Intranet to be password protected - I see this error:

**Fatal error** : Uncaught RedisException: Connection refused in /var/www/default/include/lib/container/Redis.php:42 Stack trace: #0 /var/www/default/include/lib/container/Redis.php(42): Redis->connect('redis', 6379, 0.5, '') #1 /var/www/default/include/lib/container/BaseClass.php(35): devilbox\Redis->__construct('redis', Array) #2 /var/www/default/config.php(146): devilbox\BaseClass::getInstance('redis') #3 /var/www/default/htdocs/index.php(20): loadClass('Redis') #4 {main} thrown in **/var/www/default/include/lib/container/Redis.php** on line **42**

so I found out that redis is needed for it to work - it is not mentioned in the docs.

@zuber1979 I can’t reproduce this.

I have enabled password protection and only started httpd, php and bind and can log in successfully.

Can you describe your steps a bit more detailed:

  1. What have you done
  2. Where did you see this error

I started httpd, php, mysql and bind.

I went to main intranet page and pressed “Login” - and then I see this error.

I’ve done the exact same thing and had no errors.
Can you do the following:

# Update latest Git
git fetch --all
git checkout master
git pull origin master

# Remove any existing container
docker-compose stop
docker-compose rm -f

# Update container
docker-compose pull

# Start again
docker-compose up httpd php bind

And also attach your .env file as well as provide a screenshot.

OK, I did all the steps and problem is still visible.

and .env file:

DEBUG_COMPOSE_ENTRYPOINT=1
DOCKER_LOGS=0
DEVILBOX_PATH=.
LOCAL_LISTEN_ADDR=
TLD_SUFFIX=loc
EXTRA_HOSTS=
NEW_UID=1000
NEW_GID=1000
TIMEZONE=UTC
DNS_CHECK_TIMEOUT=1
DEVILBOX_UI_SSL_CN=localhost,.localhost,devilbox,.devilbox,httpd
DEVILBOX_UI_PROTECT=1
DEVILBOX_UI_PASSWORD=blablabla
DEVILBOX_UI_ENABLE=1
DEVILBOX_VENDOR_PHPMYADMIN_AUTOLOGIN=1
DEVILBOX_VENDOR_PHPPGADMIN_AUTOLOGIN=1
PHP_SERVER=7.2
HTTPD_SERVER=apache-2.4
MYSQL_SERVER=mariadb-10.3
PGSQL_SERVER=11.1
REDIS_SERVER=5.0
MEMCD_SERVER=1.5
MONGO_SERVER=4.0
MOUNT_OPTIONS=
HOST_PATH_HTTPD_DATADIR=/home/webserver/www
HOST_PATH_TEMP_DATADIR=/home/webserver/temp
HOST_PATH_BACKUP_DATADIR=/home/webserver/backup
PHP_MODULES_ENABLE=
PHP_MODULES_DISABLE=oci8,PDO_OCI,pdo_sqlsrv,sqlsrv,rdkafka,swoole
HOST_PORT_HTTPD=80
HOST_PORT_HTTPD_SSL=443
HTTPD_DOCROOT_DIR=htdocs
HTTPD_TEMPLATE_DIR=.devilbox
HTTPD_TIMEOUT_TO_PHP_FPM=180
HTTPD_NGINX_WORKER_PROCESSES=auto
HTTPD_NGINX_WORKER_CONNECTIONS=1024
HOST_PATH_MYSQL_DATADIR= /home/webserver/sql
MYSQL_ROOT_PASSWORD=blablabla
HOST_PORT_MYSQL=5432
PGSQL_ROOT_USER=postgres
PGSQL_ROOT_PASSWORD=
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=xxx.xxx.xxx.xxx
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

Do you get this error before or after login and what URL do you use to get the above error?

I get this error after I enter login data and press “Sign in”.

I use URL of my machine as it is visible in my intranet: http://tower.company.net

  1. http://tower.company.net/index.php is the start page of the Devilbox intranet?
  2. Does it work when password protection is disabled?
  3. Does it work when you access the intranet via http://localhost and password protection enabled?

Edit: Update questions

  1. yes
  2. yes
  3. no

When password protection is enabled and I go to http://tower.company.net/index.php it redirects me to http://tower.company.net/login.php

Unfortunately I am still unable to reproduce this issue. No matter what I do, it works with or without Redis.

OK, no big issue. Works for me now with Redis.