I've got Apache installed on my local Linux (sabayon) OS, just for programming testing.
What I want is a script so that the server starts right away when I want it.
This is the code:
#!/bin/bash # een script dat de apache server start /etc/init.d/apache2 start
The only problem is that Apache needs root privileges, but I'm a normal user. Now can I run this script from the command line with
sudo ./apache_start.sh, but I don't want that. I just want to double click on it and start the Apache server.
So what can I do so the script is run as root instead of the normal user?
I don't care if there is a prompt that asks for the password, I just don't want to open a console, navigate to the file and so on.