0
votes
1answer
603 views

Create cron as a apache user and run as root user

I am creating this cron as apache user and want to run this cron as root, below is my code snippet: # Create a cron job to restart apache cron_file="/etc/cron.d/restart_apache_crontab" cron_job="*/1 ...
2
votes
1answer
875 views

How do I get simple scripts which seem to need root priveliges to run via the www-data user?

I am programming a small webinterface to control samba on Debian (kernel 2.6.32-5-686). I started by writing simple scripts to add users, create folders, etc. They worked fine when run as root. ...
2
votes
1answer
1k views

How do I restart apache as non-root (using a git-hook)?

For one specific user I want to be able to restart Apache. This user does have sudo privileges and I could run sudo /etc/init.d/apache2 reload, but I want to include this restart script in a git ...
3
votes
1answer
206 views

How do I stop Apache from running as root?

New on the job, small place, and the security stuff just landed on my desk. I was hired to be a front-end developer. Happy to learn new things, but never had to do sysadmin stuff before. I started ...