Skip to content
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

fastcgi_params file when set to non-default path if File resource not declared #1063

Closed
wyardley opened this issue Apr 5, 2017 · 0 comments

Comments

@wyardley
Copy link
Collaborator

wyardley commented Apr 5, 2017

I can try to fix this myself, but would appreciate some thoughts / suggestion (or feel free to submit a PR if someone else has a good fix).

Basically, if you set the fastcgi_params path to something non-default, Puppet still tries to manage it if the File resource doesn't exist.
The current logic is:

if $ensure == present and $fastcgi != undef and !defined(File[$fastcgi_params])

which mostly deals with the case where the user creates the fastcgi_params file except in the case where

  • the file is created by something outside of Puppet or
  • when concat is used to build the file (this is the problem I bumped up against)
  concat { $fastcgi_params_xyz:
    ensure => present,
    owner  => 'root',
    group  => 'root',
    mode   => '0644',
    notify => Service['nginx'],
  }

I think there's a param that was supposed to create a file resource, but this also didn't seem to work.

I can't think of a scenario where we'd want to use a non-default filename but manage the file with the template in the module; it would be useful to be able to use a custom template, possibly, or just to let the user define a filename that's managed elsewhere in Puppet.

https://github.com/voxpupuli/puppet-nginx/blob/master/manifests/resource/location.pp#L254-L259

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant