Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Done with day3 task. update the image folder of day3 and change solution.md file. #304

Open
wants to merge 25 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
0a93812
Done with day3 task. update the image folder of day3 and chnage solut…
Faizan2727 Oct 7, 2024
79584e2
Done with Day 4 update solution.md file
Faizan2727 Oct 8, 2024
6b2df3f
change the link of images which were broken
Faizan2727 Oct 8, 2024
709096b
Done with day5 update images folder and solution.md file
Faizan2727 Oct 9, 2024
77dbefa
done with day6 update image folder and solution.md
Faizan2727 Oct 10, 2024
77e9086
done with day7 update the images folder and solution.md file
Faizan2727 Oct 11, 2024
cde78be
updated solution.md file
Faizan2727 Oct 11, 2024
adf1740
Done with day 8 update the image folder and change the solution.md file
Faizan2727 Oct 12, 2024
2dd24e8
done with day 9 change solution.md file and image folder
Faizan2727 Oct 13, 2024
441edbd
done with day 10 change solution.md file and image folder
Faizan2727 Oct 14, 2024
26ca2d8
second time done with day 10 change solution.md file and image folder
Faizan2727 Oct 14, 2024
e3f4f24
done with day11 added solution.md to it
Faizan2727 Oct 16, 2024
4ffbd8d
done with day12 added solution.md to it
Faizan2727 Oct 16, 2024
7e3ebf5
done with day13 added solution.md to it
Faizan2727 Oct 17, 2024
d148c62
added solution.md
Faizan2727 Oct 18, 2024
72037e7
Done with day 15 added solution.md file
Faizan2727 Oct 21, 2024
bbf5db0
Done with day 16 added solution.md file
Faizan2727 Oct 21, 2024
776662c
Done with day 17 added solution.md file
Faizan2727 Oct 21, 2024
ca6b1e6
Done with day 17 added solution.md file
Faizan2727 Oct 21, 2024
44a4a6a
Done with day 18 added solution.md file
Faizan2727 Oct 22, 2024
681fb4c
Done with day 19 added solution.md file
Faizan2727 Oct 23, 2024
6d244bd
Done with day 20 added solution.md file
Faizan2727 Oct 24, 2024
24768a9
Done with day 21 added solution.md file
Faizan2727 Oct 25, 2024
cc21966
Done with day 22 added solution.md file
Faizan2727 Oct 26, 2024
c78e324
Done with day 23 added solution.md file
Faizan2727 Oct 27, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file removed 2024/day03/image/task 1.png
Binary file not shown.
Binary file removed 2024/day03/image/task 10.png
Binary file not shown.
Binary file removed 2024/day03/image/task 11.png
Binary file not shown.
Binary file removed 2024/day03/image/task 12.png
Binary file not shown.
Binary file removed 2024/day03/image/task 2.png
Binary file not shown.
Binary file removed 2024/day03/image/task 3.png
Binary file not shown.
Binary file removed 2024/day03/image/task 4.png
Binary file not shown.
Binary file removed 2024/day03/image/task 5.png
Binary file not shown.
Binary file removed 2024/day03/image/task 6.png
Binary file not shown.
Binary file removed 2024/day03/image/task 66.png
Binary file not shown.
Binary file removed 2024/day03/image/task 7.png
Binary file not shown.
Binary file removed 2024/day03/image/task 8.png
Binary file not shown.
Binary file removed 2024/day03/image/task 9.png
Binary file not shown.
Binary file added 2024/day03/image/task_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_10.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_11.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_12.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_5.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_6.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_7.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_8.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2024/day03/image/task_9.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
25 changes: 12 additions & 13 deletions 2024/day03/solution.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,49 +3,48 @@

Task 1: View the content of a file and display line numbers.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%201.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_1.png)

Task 2: Change the access permissions of files to make them readable, writable, and executable by the owner only.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%202.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_2.png)

Task 3: Check the last 10 commands you have run.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%203.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_3.png)

Task 4: Remove a directory and all its contents.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%204.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_4.png)

Task 5: Create a `fruits.txt` file, add content (one fruit per line), and display the content.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%205.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_5.png)

Task 6: Add content in `devops.txt` (one in each line) - Apple, Mango, Banana, Cherry, Kiwi, Orange, Guava. Then, append "Pineapple" to the end of the file.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%206.png)
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%2066.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_6.png)

Task 7: Show the first three fruits from the file in reverse order.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%207.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_7.png)

Task 8: Show the bottom three fruits from the file, and then sort them alphabetically.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%208.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_8.png)

Task 9: Create another file `Colors.txt`, add content (one color per line), and display the content.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%209.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_9.png)

Task 10: Add content in `Colors.txt` (one in each line) - Red, Pink, White, Black, Blue, Orange, Purple, Grey. Then, prepend "Yellow" to the beginning of the file.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%2010.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_10.png)

Task 11: Find and display the lines that are common between `fruits.txt` and `Colors.txt`.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%2011.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_11.png)

Task 12: Count the number of lines, words, and characters in both `fruits.txt` and `Colors.txt`.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day03/image/task%2012.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day03/image/task_12.png)
Binary file removed 2024/day04/image/task 1.png
Diff not rendered.
Binary file removed 2024/day04/image/task 11.png
Diff not rendered.
Binary file removed 2024/day04/image/task 2.png
Diff not rendered.
Binary file removed 2024/day04/image/task 3.png
Diff not rendered.
Binary file removed 2024/day04/image/task 4.png
Diff not rendered.
Binary file removed 2024/day04/image/task 5.png
Diff not rendered.
Binary file added 2024/day04/image/task3.png
Binary file added 2024/day04/image/task4.1.png
Binary file added 2024/day04/image/task4.png
Binary file added 2024/day04/image/task5.1.png
Binary file added 2024/day04/image/task5.png
49 changes: 38 additions & 11 deletions 2024/day04/solution.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,54 @@
# Day 4 Answers: Basic Linux Shell Scripting for DevOps Engineers

Task 1: Explain in your own words and with examples what Shell Scripting means for DevOps.
- 'Shell Scripting is writing a series of commands in a script file to automate tasks in the Unix/Linux shell. For DevOps, shell scripting is crucial for automating repetitive tasks, managing system configurations, deploying applications, and integrating various tools and processes in a CI/CD pipeline. It enhances efficiency, reduces errors, and saves time.'
- 'Shell scripting in DevOps is like giving the computer a list of instructions to automate repetitive tasks. Instead of manually typing commands every time, we write a script (a small program) to handle the work for us.

Why is it Important in DevOps?

In DevOps, automation is key. DevOps engineers use shell scripts to:
Automate deployments (e.g., push new code to servers).
Manage servers (e.g., restart services or clean up logs).
Monitor systems (e.g., check if a server is running smoothly).

Shell scripting helps in automating these daily operations, saving time, and reducing human errors.

Simple Company Example

Imagine you're working in a company that hosts a web app, and every day the following tasks need to be done:

Check if the web server is running.
Clean up old log files to free up space.
Take a backup of the database.

Now, instead of doing these tasks manually every day, we can create a shell script that runs these commands automatically!'

Example: Automating server setup
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day04/image/task%201.png)
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day04/image/task%2011.png)

Task 2: What is `#!/bin/bash`? Can we write `#!/bin/sh` as well?
- `#!/bin/bash` is called a "shebang" line. It indicates that the script should be run using the Bash shell.
- `#!/bin/bash`: Uses Bash as the interpreter. It supports advanced features like arrays, associative arrays, and functions.
- `#!/bin/sh`: Uses the Bourne shell. It’s more POSIX-compliant and is generally compatible with different Unix shells.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day04/image/task%202.png)
The line #!/bin/bash (or #!/bin/sh) at the beginning of a script is known as a shebang. It tells the operating system which interpreter to use to execute the script. Here’s a simple breakdown, along with an example relevant to a company context:

What is #!/bin/bash?

Purpose: This line indicates that the script should be run using the Bash shell. Bash is a common shell used for scripting on Unix-like operating systems.

Location: The path /bin/bash specifies where the Bash interpreter is located on the system.

What about #!/bin/sh?

Purpose: Similarly, #!/bin/sh indicates that the script should be executed using the sh shell (often referred to as the Bourne shell). This is a more minimal shell and often has fewer features than Bash.

Usage: Using #!/bin/sh is sometimes preferred for compatibility, especially if the script is simple and doesn’t require Bash-specific features.

Task 3: Write a Shell Script that prints `I will complete #90DaysOfDevOps challenge`.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day04/image/task%203.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day04/image/task3.png)

Task 4: Write a Shell Script that takes user input, input from arguments, and prints the variables.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day04/image/task%204.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day04/image/task4.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day04/image/task4.1.png)

Task 5: Provide an example of an If-Else statement in Shell Scripting by comparing two numbers.

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day04/image/task%205.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day04/image/task5.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day04/image/task5.1.png)
Binary file removed 2024/day05/image/task 1-2.png
Diff not rendered.
Binary file removed 2024/day05/image/task 1-3.png
Diff not rendered.
Binary file removed 2024/day05/image/task 1.png
Diff not rendered.
Binary file removed 2024/day05/image/task 2-1.png
Diff not rendered.
Binary file removed 2024/day05/image/task 2.png
Diff not rendered.
Binary file removed 2024/day05/image/task 3-1.png
Diff not rendered.
Binary file removed 2024/day05/image/task 3.png
Diff not rendered.
Binary file removed 2024/day05/image/task 4.png
Diff not rendered.
Binary file added 2024/day05/image/task1.png
Binary file added 2024/day05/image/task1_2.png
Binary file added 2024/day05/image/task2.png
Binary file added 2024/day05/image/task2_1.png
Binary file added 2024/day05/image/task2_3.png
Binary file added 2024/day05/image/task3.png
Binary file added 2024/day05/image/task3_2.png
Binary file added 2024/day05/image/task4.png
Binary file added 2024/day05/image/task4_1.png
20 changes: 11 additions & 9 deletions 2024/day05/solution.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,32 +10,34 @@

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day05/image/task%201.png)
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day05/image/task%201-2.png)
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day05/image/task%201-3.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task1_2.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task1_3.png)

2. **Create a Script to Backup All Your Work:**
- Backups are an important part of a DevOps Engineer's day-to-day activities. The video in the references will help you understand how a DevOps Engineer takes backups (it can feel a bit difficult but keep trying, nothing is impossible).

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day05/image/task%202.png)
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day05/image/task%202-1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task2.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task2_1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task2_2.png)

3. **Read About Cron and Crontab to Automate the Backup Script:**
- Cron is the system's main scheduler for running jobs or tasks unattended. A command called crontab allows the user to submit, edit, or delete entries to cron. A crontab file is a user file that holds the scheduling information.

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day05/image/task%203.png)
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day05/image/task%203-1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task3.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task3_2.png)

4. **Read About User Management:**
- A user is an entity in a Linux operating system that can manipulate files and perform several other operations. Each user is assigned an ID that is unique within the system. IDs 0 to 999 are assigned to system users, and local user IDs start from 1000 onwards.
- Create 2 users and display their usernames.

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day05/image/task%204.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task4.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day05/image/task4_1.png)

[LinkedIn](https://www.linkedin.com/in/bhavin-savaliya/).
[LinkedIn](https://www.linkedin.com/in/faizan-shaikh-433245194/).
Binary file modified 2024/day06/image/task1.png
Binary file modified 2024/day06/image/task3.png
Binary file removed 2024/day06/image/task4-1.png
Diff not rendered.
Binary file modified 2024/day06/image/task4.png
Binary file removed 2024/day06/image/task5-1.png
Diff not rendered.
Binary file removed 2024/day06/image/task5-2.png
Diff not rendered.
Binary file modified 2024/day06/image/task5.png
Binary file removed 2024/day06/image/task6-1.png
Diff not rendered.
Binary file removed 2024/day06/image/task6.png
Diff not rendered.
Binary file added 2024/day06/image/task_4_1.png
Binary file added 2024/day06/image/task_6_1.png
Binary file added 2024/day06/image/task_6_2.png
23 changes: 11 additions & 12 deletions 2024/day06/solution.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
- Task: Change the user permissions of the file and note the changes after running `ls -ltr`.

**Answer**
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day06/image/task1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day06/image/task1.png)

2. **Writing an Article:**
- Write an article about file permissions based on your understanding from the notes.
Expand Down Expand Up @@ -54,18 +54,20 @@
- Task: Create a directory and set specific ACL permissions for different users and groups. Verify the permissions using `getfacl`.

**Answer**
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day06/image/task3.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day06/image/task3.png)

4. **Additional Tasks:**
- **Task:** Create a script that changes the permissions of multiple files in a directory based on user input.

**Answer**
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day06/image/task4.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day06/image/task4.png)


- **Task:** Write a script that sets ACL permissions for a user on a given file, based on user input.

**Answer**
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day06/image/task4-1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day06/image/task_4_1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day06/image/task_4_2.png)

5. **Understanding Sticky Bit, SUID, and SGID:**
- Read about sticky bit, SUID, and SGID.
Expand All @@ -75,20 +77,17 @@
- Task: Create examples demonstrating the use of sticky bit, SUID, and SGID, and explain their significance.

**Answer**
- Sticky bit:
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day06/image/task5.png)
- SUID:
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day06/image/task5-1.png)
- SGID:
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day06/image/task5-2.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day06/image/task5.png)



6. **Backup and Restore Permissions:**
- Task: Create a script that backs up the current permissions of files in a directory to a file.

**Answer**
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day06/image/task6.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day06/image/task_6_1.png)

- Task: Create another script that restores the permissions from the backup file.

**Answer**
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day06/image/task6-1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day06/image/task_6_2.png)
Binary file removed 2024/day07/image/task1-2.png
Diff not rendered.
Binary file removed 2024/day07/image/task1.png
Diff not rendered.
Binary file removed 2024/day07/image/task4.png
Diff not rendered.
Binary file removed 2024/day07/image/task5-1.png
Diff not rendered.
Binary file removed 2024/day07/image/task5.png
Diff not rendered.
Binary file removed 2024/day07/image/task6-1.png
Diff not rendered.
Binary file removed 2024/day07/image/task6.png
Diff not rendered.
Binary file added 2024/day07/image/task_1.png
Binary file added 2024/day07/image/task_2.png
Binary file added 2024/day07/image/task_4.png
Binary file added 2024/day07/image/task_4_2.png
Binary file added 2024/day07/image/task_5.png
Binary file added 2024/day07/image/task_5_1.png
Binary file added 2024/day07/image/task_6.png
Binary file added 2024/day07/image/task_6_2.png
Binary file removed 2024/day07/image/taskj2.png
Diff not rendered.
20 changes: 11 additions & 9 deletions 2024/day07/solution.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,15 +52,16 @@
sudo apt install default-jre

Output
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day07/image/task1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_1.png)

Output (Jenkins-UI)
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day07/image/task1-2.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_2.png)

2. **Write a Blog or Article:**
- Write a small blog or article on how to install these tools using package managers on Ubuntu and CentOS.

**Answer**
[Article and Blog here](https://faizanshaikh.hashnode.dev/day-7-task-understanding-package-manager-and-systemctl)
1. Introduction:
- Briefly introduce Docker and Jenkins.
- Mention the operating systems (Ubuntu and CentOS) covered.
Expand All @@ -83,13 +84,13 @@ Systemctl is used to examine and control the state of the “systemd” system a
- Check the status of the Docker service on your system (ensure you have completed the installation tasks above).

**Answer**
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day07/image/task5.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_5.png)

2. **Manage Jenkins Service:**
- Stop the Jenkins service and post before and after screenshots.

**Answer**
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day07/image/taskj2.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_5_1.png)

3. **Read About Systemctl vs. Service:**
- Read about the differences between the `systemctl` and `service` commands.
Expand Down Expand Up @@ -144,24 +145,25 @@ Systemctl is used to examine and control the state of the “systemd” system a
- Write a script to automate the starting and stopping of Docker and Jenkins services.

**Answer**
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day07/image/task4.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_4.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_4_2.png)

5. **Enable and Disable Services:**
- Use systemctl to enable Docker to start on boot and disable Jenkins from starting on boot.

**Answer**
- Enable Docker to start on boot:
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day07/image/task5.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_5.png)

- Disable Jenkins from starting on boot:
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day07/image/task5-1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_5_1.png)

6. **Analyze Logs:**
- Use journalctl to analyze the logs of the Docker and Jenkins services. Post your findings.

**Answer**
- Docker Logs:
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day07/image/task6.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_6.png)

- Jenkins Logs:
![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day07/image/task6-1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day07/image/task_6_2.png)
Binary file removed 2024/day08/image/task1.png
Diff not rendered.
Binary file removed 2024/day08/image/task2.png
Diff not rendered.
Binary file removed 2024/day08/image/task3.png
Diff not rendered.
Binary file removed 2024/day08/image/task4.png
Diff not rendered.
Binary file removed 2024/day08/image/task5.png
Diff not rendered.
Binary file removed 2024/day08/image/task6.png
Diff not rendered.
Binary file added 2024/day08/image/task_1.png
Binary file added 2024/day08/image/task_2.png
Binary file added 2024/day08/image/task_3.png
Binary file added 2024/day08/image/task_4.png
Binary file added 2024/day08/image/task_5.png
Binary file added 2024/day08/image/task_6.png
Binary file added 2024/day08/image/task_7.png
Binary file added 2024/day08/image/task_8.png
19 changes: 12 additions & 7 deletions 2024/day08/solution.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,41 +7,46 @@

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day08/image/task1.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day08/image/task_1.png)

2. **Echo**
- The echo command is used to display messages on the terminal. Your task is to create a bash script that uses echo to print a message of your choice.

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day08/image/task2.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day08/image/task_2.png)

3. **Variables**
- Variables in bash are used to store data and can be referenced by their name. Your task is to create a bash script that declares variables and assigns values to them.

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day08/image/task3.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day08/image/task_3.png)

4. **Using Variables**
- Now that you have declared variables, let's use them to perform a simple task. Create a bash script that takes two variables (numbers) as input and prints their sum using those variables.

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day08/image/task4.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day08/image/task_4.png)

5. **Using Built-in Variables**
- Bash provides several built-in variables that hold useful information. Your task is to create a bash script that utilizes at least three different built-in variables to display relevant information.

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day08/image/task5.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day08/image/task_5.png)

6. **Wildcards**
- Wildcards are special characters used to perform pattern matching when working with files. Your task is to create a bash script that utilizes wildcards to list all the files with a specific extension in a directory.

**Answer**

![image](https://github.com/Bhavin213/90DaysOfDevOps/blob/master/2024/day08/image/task6.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day08/image/task_6.png)
Comment on lines +24 to +45
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

LGTM for image updates. Task numbering needs attention.

The image links for Tasks 3-6 have been correctly updated to the new repository and filename convention.

However, there's a task numbering issue:

  • There are two tasks labeled as "6" (Wildcards and Full_script).
  • This may cause confusion for readers.

Please renumber the tasks to ensure a sequential order:

  1. Comments
  2. Echo
  3. Variables
  4. Using Variables
  5. Using Built-in Variables
  6. Wildcards
  7. Full_script
🧰 Tools
🪛 LanguageTool

[duplication] ~40-~40: Possible typo: you repeated a word
Context: ...24/day08/image/task_5.png)

  1. Wildcards
    • Wildcards are special characters used to perform ...

(ENGLISH_WORD_REPEAT_RULE)


[LinkedIn](https://www.linkedin.com/in/bhavin-savaliya/)
6. **Full_script**
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day08/image/task_7.png)
![image](https://github.com/Faizan2727/90DaysOfDevOps/blob/master/2024/day08/image/task_8.png)


[LinkedIn](https://www.linkedin.com/in/faizan-shaikh-433245194/)
Binary file removed 2024/day09/image/bash1.png
Diff not rendered.
Binary file added 2024/day09/image/task.png
Binary file removed 2024/day09/image/task1-2.png
Diff not rendered.
Binary file removed 2024/day09/image/task11.png
Diff not rendered.
Binary file removed 2024/day09/image/task2.png
Diff not rendered.
Binary file removed 2024/day09/image/task3.png
Diff not rendered.
Binary file added 2024/day09/image/task_1.png
Binary file added 2024/day09/image/task_2.png
Loading