-
Notifications
You must be signed in to change notification settings - Fork 325
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove env placeholder regexp #422
Conversation
f4d50c2
to
fdec2b2
Compare
fix snc#356 This is an internal detail that is not covered by the BC policy of Symfony and can thus break on any version We now detect if env variable is used by checking the 3rd parameter of method ContainerBuilder::resolveEnvPlaceholders
Thanks! I'll see when I can test this soon-ish. |
@curry684 As a second step I would be very happy to merge |
Thanks! |
I am not sure to understand the details of this PR, but I think it broke my setup (Redis::connect(): php_network_getaddresses: getaddrinfo failed: Name does not resolve). I debugged a bit: as <?php
use Symfony\Component\DependencyInjection\Argument\RewindableGenerator;
// This file has been auto-generated by the Symfony Dependency Injection Component for internal use.
// Returns the public 'snc_redis.session.handler' shared service.
$a = new \Snc\RedisBundle\Client\Phpredis\Client(array('alias' => 'default'), ($this->privates['snc_redis.logger'] ?? $this->getSncRedis_LoggerService()));
$a->connect(NULL, 6379, 5);
$a->setOption(1, 0);
return $this->services['snc_redis.session.handler'] = new \Snc\RedisBundle\Session\Storage\Handler\RedisSessionHandler($a, $this->parameters['session.storage.options'], 'session', true, 150000); As you can see, the client tries to connect to snc_redis:
clients:
default:
type: phpredis
alias: default
dsn: 'redis://%env(REDIS_HOST)%'
session:
client: default I can try to create a reproducer but I don't think it should be difficult to create one using a basic Symfony 4 project as it's a container build issue. Thanks for this great bundle and your work in open-source :) ! |
I confirm the issue, it happened only with
Instead we should use a sort of I guess the issue should be reopened too. |
Reopened #356 |
fix #356
This is an internal detail that is not covered by the BC policy of Symfony and can thus break on any version.
We now detect if env variable is used by checking the 3rd parameter of method
ContainerBuilder::resolveEnvPlaceholders
Note that we still have an issue with profile option that is not resolved at runtime.