Skip to content

Conversation

@mforbak
Copy link
Contributor

@mforbak mforbak commented Jul 21, 2020

Q A
Branch? 4.4
Bug fix? yes
New feature? no
Deprecations? no
Tickets -
License MIT
Doc PR -

Currently it is not possible to connect to RedisCluster with password. AUTH param is described in documentation (last example) https://symfony.com/doc/current/components/cache/adapters/redis_adapter.html#configure-the-connection but totally ignored in the code and connection fails

RedisAdapter::createConnection(
    'redis:?host[localhost]&host[localhost:6379]&host[/var/run/redis.sock:]&auth=my-password&redis_cluster=1'
);

See RedisCluster usage here https://github.com/phpredis/phpredis/blob/develop/cluster.markdown#declaring-a-cluster-with-an-array-of-seeds

@nicolas-grekas nicolas-grekas changed the title Connect to RedisCluster with password auth [Cache] Connect to RedisCluster with password auth Jul 22, 2020
@nicolas-grekas
Copy link
Member

Can you please rebase+target branch 4.4, and also fill in the PR template properly in the description?

@mforbak mforbak changed the base branch from master to 4.4 July 22, 2020 12:47
@mforbak mforbak changed the base branch from 4.4 to master July 22, 2020 12:49
Currently it is not possible to connect to RedisCluster with password. AUTH param is described in documentation (last example) https://symfony.com/doc/current/components/cache/adapters/redis_adapter.html#configure-the-connection but totally ignored in the code and connection fails

```
RedisAdapter::createConnection(
    'redis:?host[localhost]&host[localhost:6379]&host[/var/run/redis.sock:]&auth=my-password&redis_cluster=1'
);
```

See RedisCluster usage here https://github.com/phpredis/phpredis/blob/develop/cluster.markdown#declaring-a-cluster-with-an-array-of-seeds
@nicolas-grekas nicolas-grekas changed the base branch from master to 4.4 July 23, 2020 09:54
@nicolas-grekas
Copy link
Member

Thank you @mforbak.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants