Skip to content

Redis password AUTH issue in docker-compose example #1608

Description

@laenan8466

We need to update this example (docker-compose/with-nginx/mariadb/fpm), to handle the redis-db password issue (#1179).

Other docker-compose examples could be affected as well.

I fixed the problem by:

  1. Adding a redis.env file with:
    REDIS_HOST_PASSWORD=mypassword
  2. Modifiying the docker-compose.yml file in the following sections:
  app:
    image: nextcloud:fpm-alpine
    restart: always
    volumes:
      - nextcloud:/var/www/html
    environment:
      - MYSQL_HOST=db
      - REDIS_HOST=redis
    env_file:
      - redis.env
      - db.env
    depends_on:
      - db
      - redis
  redis:
    image: redis:alpine
    restart: always
    command: /bin/sh -c "redis-server --requirepass $$REDIS_HOST_PASSWORD"
    env_file:
      - redis.env

I have not the time atm to submit a PR, but wanted to have this documented.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions