I struggle to find a way to disable the trace/track option on one of my RHEL7 servers which is controlled by puppet.
I'm using apache module of puppetlabs.
I want to disable TraceEnable in the httpd.conf file on a single server and not to all servers managed by puppet.
The directive I need to add using puppet is:
TraceEnable Off
I have the YAML file for the server in the location:
/etc/puppetlabs/code/environments/test/data/node/server1.yaml
I can edit this file to apply the config on this server only but I don't know what to put in it.
How to call the HTTP module and how to right the directive in the YAML file?
CodePudding user response:
The reference documentation for the puppetlabs-apache module is available from the Puppet Forge. It would tell you that the main class of that module (apache
) has a parameter trace_enable, which controls exactly the httpd configuration property you want to manage:
Controls how Apache handles
TRACE
requests (per RFC 2616) via theTraceEnable
directive.Default value:
'On'
Provided that your manifest set is not explicitly specifying a value for that parameter, you should be able to customize it on a per-node basis by setting the apache::trace_enable
key in node-specific hiera data. For example, if the node specific data for the node you want to configure is environments/production/data/node/server1.yaml
, then in that file, include the line
apache::trace_enable: 'Off'