I need to create a bash file with a few commands. What I'm trying to do is a web interface to copy a directory into another directory and vice versa (two hyperlinks).
One link I want it to do:
cp /var/www/test /var/www/backup/test022207
cp /var/www/live /var/www/test
The other link I want:
cp /var/www/live /var/www/backup/live022207
cp /var/www/test /var/www/live
Not sure if it's possible to run a bash command from the web or I have to use Perl/CGI to do it. Any idea how I would accomplish this?
Our community of experts have been thoroughly vetted for their expertise and industry experience.