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

Ensure the lock_dir is owned by www-data for Apache 2.2 and 2.4 on Debian/Ubuntu #450

Merged

Conversation

meineerde
Copy link
Contributor

@meineerde meineerde commented Oct 31, 2016

Description

The default apache2ctl script for both Apache 2.2 and 2.4 creates the lock_dir in /var/lock/apache2. If the directory exists but is not owned by www-data, the script fails, similar to what is described in #310 and #312.

Issues Resolved

This commit enhances the fix from #312 for Apache 2.4 in Debian/Ubuntu.

Check List

…bian/Ubuntu

The default `apache2ctl` script for both Apache 2.2 and 2.4 creates the
lock_dir in `/var/lock/apache2`. If the directory exists but is not owned
by `www-data`, the script fails, similar to what is described in sous-chefs#310
and sous-chefs#312.

This commit enhances the fix from sous-chefs#312 for Apache 2.4 in Debian/Ubuntu.
@meineerde
Copy link
Contributor Author

Note that the failing test is due to unrelated Foodcritic complaints.

As for testing, I'm not sure this warants new tests since the previous behavior is not tested either. This pull request just extends existing functionality from version 2.2 to version 2.4.

@svanzoest svanzoest merged commit 2977370 into sous-chefs:master Nov 6, 2016
@svanzoest svanzoest self-assigned this Nov 6, 2016
@meineerde
Copy link
Contributor Author

And now just that you merged it (thanks for that!) I find the typo...

%(2.2 2.4) is equal to "2.2 2.4". So while it works fine with a string comparison, it is not entirely correct since it actually should compare to an Array, i.e %w(2.2 2.4).

I just pushed another commit to my branch to fix this.

@svanzoest
Copy link
Contributor

You can not do a version check on apache.version like that as it is a flag. So I removed it entirely

@meineerde
Copy link
Contributor Author

Ah, and now, as I actually read the connected commit, it all makes sense. Thank you, keep up the good work!

@lock
Copy link

lock bot commented Jul 24, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot unassigned svanzoest Jul 24, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Jul 24, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants