You have created the directory structure and some base files to be used by the Web server and Web site. For the Web site to be created in a production environment, you need to package your commands in a script so that the patching team can run them on the production enviro nment. Your task for this assignment is the following: Create a Bourne shell script. The script should do the following:   Explain what the script will do and who is the author in a comment area. cd to your home directory Show your current working directory. List the contents of the current directory. Create the directory structure and create the files as defined in the previous Individual Project. For each directory and file, test to see if the file or directory already exists; if it does exist, do not recreate; if it is missing, create it. In the end, generate a directory listing showing the structure and content of the new directories. At the beginning of the script, set a variable called INSTALL_DIRECTORY that will contain the location of the directory into which the Web server will be installed. At the end of the script, display the contents of this variable along with a message to the installer about the location in which the directories were created.   A small hint for creating the content of the httpd.conf file: use the echo command in your script. The script is not interactive and should create all objects automatically. Also, the ServerRoot and DocumentRoot should contain correct values based on your directory names. If you need to test that directories are created or not based on them already existing, remove files and directories ahead of time to ensure you know the exact state of your environment.

LINUX+ AND LPIC-1 GDE.TO LINUX CERTIF.
5th Edition
ISBN:9781337569798
Author:ECKERT
Publisher:ECKERT
Chapter11: Compression, System Backup, And Software Installation
Section: Chapter Questions
Problem 3DE
icon
Related questions
Question

You have created the directory structure and some base files to be used by the Web server and Web site. For the Web site to be created in a production environment, you need to package your commands in a script so that the patching team can run them on the production enviro

nment. Your task for this assignment is the following:

Create a Bourne shell script. The script should do the following:

 

  1. Explain what the script will do and who is the author in a comment area.
  2. cd to your home directory
  3. Show your current working directory.
  4. List the contents of the current directory.
  5. Create the directory structure and create the files as defined in the previous Individual Project.
  6. For each directory and file, test to see if the file or directory already exists; if it does exist, do not recreate; if it is missing, create it.
  7. In the end, generate a directory listing showing the structure and content of the new directories.
  8. At the beginning of the script, set a variable called INSTALL_DIRECTORY that will contain the location of the directory into which the Web server will be installed. At the end of the script, display the contents of this variable along with a message to the installer about the location in which the directories were created.

 

A small hint for creating the content of the httpd.conf file: use the echo command in your script. The script is not interactive and should create all objects automatically. Also, the ServerRoot and DocumentRoot should contain correct values based on your directory names.

If you need to test that directories are created or not based on them already existing, remove files and directories ahead of time to ensure you know the exact state of your environment.

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps

Blurred answer
Knowledge Booster
Creating a local network
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
LINUX+ AND LPIC-1 GDE.TO LINUX CERTIF.
LINUX+ AND LPIC-1 GDE.TO LINUX CERTIF.
Computer Science
ISBN:
9781337569798
Author:
ECKERT
Publisher:
CENGAGE L
A+ Guide To It Technical Support
A+ Guide To It Technical Support
Computer Science
ISBN:
9780357108291
Author:
ANDREWS, Jean.
Publisher:
Cengage,