Earlier I explained how to run websites from the home. Today I will tell how to configure for cgi-bin so that you can run cgi scripts from home itself.
1. Open /etc/apache2/httpd.cfg file.
$ sudo vi /etc/apache2/httpd.cfg file
2. Copy the following lines in it.
ScriptAlias /cgi-bin/ /home/priyanka/public_html/cgi-bin/ <Directory /home/priyanka/public_html/cgi-bin/> AllowOverride None Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch SetHandler cgi-script Order allow,deny Allow from all AddHandler cgi-script .cgi .pl </Directory>
3. Restart the apache with the following command:
$ sudo /etc/init.d/apache2 restart
And you are done. 🙂