Table of contents
- DAY-4 TASKS
- 1 - Explain in your own words and examples, what is Shell Scripting for DevOps.
- 2 - What is #!/bin/bash? can we write #!/bin/sh as well?
- 3 - Write a Shell Script that prints I will complete the#90DaysofDevOps challenge.
- 4 - Write a Shell Script to take user input, input from arguments and print the variables.
- 5-Write an Example of If else in Shell Scripting by comparing 2 numbers
DAY-4 TASKS
1 - Explain in your own words and examples, what is Shell Scripting for DevOps.
The shell script is a computer program designed to be run by the Unix/Linux shell.
Shell Script is a series of commands.
A shell script can be used to prepare input files, job monitoring and output processing.
To automate some daily tasks like backup and monitoring.
2 - What is
#!/bin/bash?
can we write#!/bin/sh
as well?
#!/bin/bash is known as shebang or bang line.
It is the absolute path to the bash interpreter.
script files use the shebang line “#!/bin/bash” to set bash.
Yes, we can write #!/bin/sh because “bash” and “sh” are two different shells. Bash has the same abilities as Shell, but it developed other functions and better extensions over time.
3 - Write a Shell Script that prints
I will complete the#90DaysofDevOps challenge.
-
4 - Write a Shell Script to take user input, input from arguments and print the variables.
-
5-Write an Example of If else in Shell Scripting by comparing 2 numbers
-
TASK COMPLETED!!