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

Implement php_value and php_flag #906

Merged
merged 4 commits into from
Dec 19, 2014
Merged

Implement php_value and php_flag #906

merged 4 commits into from
Dec 19, 2014

Conversation

jweisner
Copy link
Contributor

MODULES-1320 php_value option not available

@igalic
Copy link
Contributor

igalic commented Oct 22, 2014

@jweisner the main reason i didn't implement php_value|php_flag is that they can be overwritten in .htaccess, or in the app itself, so i'm finding it not really all that useful from an admin point of view

i might have explicitly stated that as such, somewhere. in an issue tracker that no longer exists…

@jweisner
Copy link
Contributor Author

A lot of the configuration options available in the puppetlabs-apache module could be set with .htaccess directives, and php options could also be set in php.ini. When I saw php_admin_value was an option I naturally assumed php_value was as well.

The use-case for "non-admin" PHP options in the server config is that different virtual hosts often need different "reasonable defaults" for things like include_path.

The larger issue here seems to be that adding every configuration option exposed by every module will spiral out of control rather quickly, and I'm not sure how to solve this. Maybe the right thing to do is abstract away all non-core directives into something more generic? I don't find custom_fragment to be an elegant solution, but maybe I'm doing it wrong?

@igalic
Copy link
Contributor

igalic commented Oct 23, 2014

my beef, in this particular instance here, is with .htaccess.
if you control the application configuration, you should _not_ use .htaccess.
it opens up a whole can of worms of security and performance issues.

but, yes, adding more and more and more directives to vhost isn't going to be the solution.
i'm still hoping for a peaceful hour or so to sit down with @mhaskel and design a better one.

@bschonec
Copy link

bschonec commented Nov 5, 2014

I'm not asking for EVERY variable to be available, just that I can add "php_value " to the apache .conf file. I think it would be easy just to make a (two dimensional?) array where I can just dump the value of the array into the puppet manifest's variable.

I do think it's important to be able to control the conf file from your puppet module. I realize the security implications of overwriting the values with .htaccess but IMHO making the apache admin search in multiple places for configuration options makes things more difficult.

@cubiclelord
Copy link

I have a use case for allowing php_value. We set a basic include path via php_value, but allow our web developers in their code to append other includes as well. I assume they do this so we don't have to change our include path in Puppet every time they want to add another include path.

I am currently using custom_fragment to get around this, but it would be nice if we didn't have to.

@Spechal
Copy link

Spechal commented Dec 13, 2014

Things like NewRelic can use php_value values in a vhost

+1 for need

underscorgan pushed a commit that referenced this pull request Dec 19, 2014
Implement php_value and php_flag
@underscorgan underscorgan merged commit 4f6acff into puppetlabs:master Dec 19, 2014
@underscorgan
Copy link
Contributor

@jweisner thanks for the contribution!

@jweisner jweisner deleted the php_value branch December 20, 2014 01:47
@jweisner jweisner restored the php_value branch December 20, 2014 01:48
@jweisner jweisner deleted the php_value branch December 27, 2014 02:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants