voxpupuli / voxpupuli/puppet-php
FPM pools can't be specified in code
Nobody has claimed this yet.
- Dominant language
- Puppet
- Stars
- 86
- Forks
- 264
- Avg merge
- 29m
- Merged PRs (30d)
- 1
Description
Affected Puppet, Ruby, OS and module versions/distributions
- Puppet: 6.12
- Ruby: 2.5.1
- Distribution: ubuntu 18.04
- Module version: 7.1.0
How to reproduce (e.g Puppet code you use)
class { 'php':
fpm => true,
fpm_pools => {
'www' => {
'listen' => '0.0.0.0:9000',
},
},
}
What are you seeing
FPM is listening on localhost only (code above specifies all interfaces)
root@29b721b3c7a6:/# grep 'listen =' /etc/php/7.2/fpm/pool.d/www.conf
listen = 127.0.0.1:9000
What behaviour did you expect instead
FPM is listening on all interfaces
root@29b721b3c7a6:/# grep 'listen =' /etc/php/7.2/fpm/pool.d/www.conf
listen = 0.0.0.0:9000
Output log
Any additional information you'd like to impart
I believe this is caused by #550. Hiera settings override the parameter default which is set to take the values from class php.
I tried to provide a test showing the expected behavior, but I couldn't figure out how and the test suite is broken anyway.
A possible solution might be to have the hiera defaults for php::fpm_pools instaed of php::fpm::pools, but that might well be a breaking change.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Trace how the php::fpm_pools class parameter and the php::fpm::pools Hiera defaults are merged, using the reported Puppet example as the starting point. Check the existing test suite, which the report says is broken, and consider the compatibility impact of changing the Hiera defaults. Done means the generated pool configuration uses 0.0.0.0:9000 when specified in code.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- devops, infrastructure
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100