r/PHPhelp • u/BigBootyBear • Aug 10 '25
Do you keep the apache comments in your apache.conf?
After you know what each thing does it's just clutter. Is there some best practice to never remove them, or can you remove them to make the file less cluttered? Im talking about the default comments, not developer ones.
6
Upvotes
4
u/equilni Aug 10 '25
Apologies, shouldn't this belong in r/apache ?
1
u/larsnielsen2 Aug 10 '25
Make the comments in your version controlled configuration management system(puppet)
1
u/lachlan-00 Aug 10 '25
When the os updates config files your diff will be too hard to read
1
u/Spiritual_Cycle_3263 Aug 10 '25
Yes, I remove comments and only comment the default out to whatever I change it to. Same with all my configs. I save the original file if needed.Â
cp apache.conf apache.config.bk
  # key = value
  key = new value
Makes it easy to know what you changed. Especially for php.ini files that can be very long.Â
-2
u/colshrapnel Aug 10 '25
It is considered best practice to remove Apache wholly, along with its configuration files and comments in them.
Speaking of your question, I don't see any point in that. This file is not something you are checking pretty often so even as a "clutter" it does no harm. not to mention other people that may be not as faliliar as yourself. Assuming we are talking of httpd.conf, as I have no idea what apache.conf is.