Skip to content

Remove extraneous use of sudo from /etc/cron.d/mailinabox-nextcloud #2500

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

jtickle
Copy link

@jtickle jtickle commented Apr 12, 2025

I installed logwatch to be a little more aware of what's going on and noticed that sudo was being used regularly throughout the day by root to become www-data and run nextcloud maintenance scripts.

The file /etc/cron.d/mailinabox-nextcloud created by setup/nextcloud.sh was created such that it runs as root but then sudo's to www-data to run the nextcloud maintenance commands.

My change just puts www-data in the cron user field and eliminates the need for sudo. Tested on my install.

Copy link
Contributor

@kiekerjan kiekerjan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested, looks good.

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

Successfully merging this pull request may close these issues.

2 participants