Contents:

  1. Linux Basics:

    1.1 Basic Commands

    1.2 Virtualization & Hypervisors

    1.3 Linux FS

  2. Infrastructure as Code:

    2.1 Infra provisioning: Terraform

    2.2 Configuration management: Ansible, chef etc.

  3. Containers

  4. CI/CD Pipeline: Jenkins(using Groovy)

  5. Basics of Infrastructures: IaaS like AWS, GCP

  6. Container orchestration using Kubernetes

  7. Monitoring Tools: Prometheus, Nagios

  8. Scripting Language

    8.1 System Dependent: Bash, etc.

    8.2 System Independent: Ruby, Python, Go

Linux Basics:

  1. Linux Commands

    touch test.txt: Create a txt file named test

    cd: change directory

    ls: List contents of current dir

    ls -lart: View files along with their permissions(rwx: read,write,execute stated in order owner, group, public)

    chmod: Manage file system access permissions

    To create a file by specifying permissions:

    1. Use chmod calc to find octal value for permissions: https://chmod-calculator.com/
    # The first digit represents the owner of the file/directory
    # The second digit represents the group that the file/directory belongs to
    # The third digit represents all other users
    # 0 (no permission)
    # 1 (execute only)
    # 2 (write only)
    # 3 (write and execute)
    # 4 (read only)
    # 5 (read and execute)
    # 6 (read and write)
    # 7 (read, write, and execute)
    
    1. chmod <octal value> file: Sets permissions with given octal value to the specified filename

    Note: For all permissions to owner, group and user octal value is 777

    chown: change owner

    pwd: present working dir

    mkdir: create dir

    rmdir -r/-rf: remove dir

    cp file1 file2: copy file1 to new or existing file2

    vim: :q=exit, :wq=save exit, :q! = undo changes

    htop: interactive process view for system monitoring

    (sudo) apt update: Update all installed packages

    (sudo) apt install <package_name>: Install a package

    tar: create/extract .tar archive files(files having one or more files and metadata), Example: tar -xJvf filename.tar.xz

    gzip/gunzip file.txt: gzip to Compress files & gunzip to decompress

    ssh username@server_address : Connect to remote server securely

    mv example.txt backup/ : Move/rename files netstat : Display network connection info

    route [options] [add/delete/show] : view or configure network routing table

    systemctl :control system services and settings

    # Start the nginx service
    systemctl start nginx
    
    # Check the status of the nginx service
    systemctl status nginx
    
    # Stop the nginx service
    systemctl stop nginx
    

    useradd : Add new user, Example: useradd testuser

    locate file.txt : Locate a file

    history : Command history

    uname/uname -a : Display system info

    uptime : System load and # of current users

    df: Display disk space usage

    du: Disk usage by file/dir

    1. Virtualization

      In cloud computing, Virtualization simply means creating a virtual version of something rather than a physical form. Examples: Application, Storage, Network, Desktop, Server.

      Hypervisors for Server Virtualization: In simple terms, it is a software installed on a server to segregate different VMs.

      how-does-a-hypervisor-work-1536x749.png

      Two types of HyperVs:

      Type 1/Bare Metal:

      • Widely used, Self managing, Installed directly on physical hardware, Examples: VMware ESXi, Microsoft Hyper-V, Xen

      Type 2/ Hosted:

      • Installed on OS, Create VMs within the OS,

        Examples: VMware Workstation, Oracle VirtualBox.

      Advantages of HyperVs:

      • Cost savings
      • Agility+Speed
      • Reduced downtimes: Its easy to shift VMs from one hyperV to other
      1. Linux File System

        🗃️ /bin: Binaries — This directory holds the essential user command binaries that all users can access.

        🔧 /sbin: System Binaries — Contains the essential binaries used by the system administrator for system maintenance and troubleshooting.

        ⚙️ /etc: System Configuration — Houses the system configuration files, acting as the control panel on Linux.

        ⚙️ /etc: System Configuration — Houses the system configuration files, acting as the control panel on Linux. Has info on all grps like docker, ssh etc ;)

        💽 /dev: Device Files — Home to all device files, such as hard disks, USB, CD-ROM, etc. 📊 /proc: Process Information — A virtual directory detailing system and process information. 📁 /var: Variable Files — This is the variable data directory storing changing data like logs, mails, print spools, etc.

        🗑️ /tmp: Temporary Files — This directory stores temporary files created by the system and users.

        👥 /usrUser Binaries — Contains multi-user utilities, applications, and libraries. 🏠 /home: User Home Directories — Contains the home directories for users and other accounts. 📚 /libSystem Libraries — Houses library files that are needed by the system and the users. 🎁 /opt: Optional Software — Stores optional or additional software from vendors. 📝 /mnt: Mount Directory — Used for mounting other temporary file systems. 💿 /media: Removable Media — Acts as a temporary mount directory for removable devices. 🔨 /srv: Service Data — This directory contains server-specific services-related data. 🚀 /boot: Boot Files — Contains boot loader-related files. Keep safe distance from this folder ☠️

        👑 /root: Root Home — This is the home directory for the root user.

        🔌 /run: Application Information — A tmpfs file system that contains application information.

        🧑‍🔬 /usr/local: User Local — Contains user’s programs that are installed from the source.

        📦 /lib64: 64-bit Libraries — This is where the 64-bit library files are stored.

Infrastructure as a code(IaC):

Provisioning cloud resources:

Screenshot (3).png

Categories of IaC: