linux_wiki:deploy_a_basic_cgi_application

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
linux_wiki:deploy_a_basic_cgi_application [2016/08/28 23:24]
billdozor created
linux_wiki:deploy_a_basic_cgi_application [2019/05/25 23:50] (current)
Line 4: Line 4:
  
 Deploying a basic CGI application via a bash script. Deploying a basic CGI application via a bash script.
 +
 +----
 +
 +====== Lab Setup ======
 +
 +The following virtual machines will be used:
 +  * server1.example.com (192.168.1.150) -> Perform all connectivity tests from here
 +  * server2.example.com (192.168.1.151) -> Install Apache Web Server here
 +
 +
 +**Previous Sections Completed**
 +  * [[linux_wiki:network_services_overview_apache_web_server|Install/Configure]]
 +    * Except leave listening on port 80/tcp
 +  * [[linux_wiki:configure_a_virtual_host|Virtual Host Config]]
  
 ---- ----
Line 14: Line 28:
  
 #!/bin/bash #!/bin/bash
-echo "Content-type: text" +echo -e "Content-type: text\n"
-echo+
 echo "This is the current time on the system: $(date)" echo "This is the current time on the system: $(date)"
 </code> </code>
 +  * **Note**: There MUST be a newline after the "Content-type: text" line in order for the cgi script to work correctly. (Either in the form above with 'echo -e' and the '\n' or another empty echo command) 
  
 \\ \\
Line 40: Line 54:
 Test CGI deployed script Test CGI deployed script
 <code bash> <code bash>
-elinks http://testsite.example.com/cgi-bin/mytime.sh+elinks http://bluesite.example.com/cgi-bin/mytime.sh
 </code> </code>
  
 ---- ----
  
  • linux_wiki/deploy_a_basic_cgi_application.1472441067.txt.gz
  • Last modified: 2019/05/25 23:50
  • (external edit)