Python for Linux Admins: Automate & Script Tasks
Automate files, users & processes, run shell commands, use APIs, sockets & build real-world DevOps scripts
Automate files, users & processes, run shell commands, use APIs, sockets & build real-world DevOps scripts
Hello Everyone
Welcome to the Python course designed for Linux Admins. This course introduces you to the practical application of Python in system administration workflows.
We begin with setting up Python, understanding its significance in Linux and DevOps, and exploring the essential tools and technologies used throughout the course. You'll learn the basics of Python, including syntax, data types, and essential programming constructs such as loops, conditional statements, and commonly used data structures like lists, tuples, sets, and dictionaries.
The course emphasizes the importance of functions and modules, teaching you how to create reusable code, organize projects, and leverage Python's extensive standard library. We'll also cover file handling and exception management to help you build robust scripts.
As system interaction is a crucial skill, you'll gain hands-on experience working with Python's OS-related modules, enabling you to automate system tasks effectively. The course provides real-world examples, ensuring that every concept is tied to practical applications in Linux and DevOps environments.
By the end of the course, you'll be equipped with the foundational skills required to write efficient Python scripts and automate repetitive tasks, enhancing your productivity as a Linux administrator or DevOps engineer. This comprehensive course ensures you’re ready for real-world challenges.
FAQ area empty
Conditional statements (if, elif, else)
475 Xem trướcLooping Constructs (for, while)
359Lab: Looping Constructs (for, while)
342Loop Control Statements (break, continue, pass)
193 Xem trướcLab: Loop Control Statements (break, continue, pass)
352 Xem trướcLists, Tuples, Sets, and Dictionaries
290Lab: Lists, Tuples, Sets, and Dictionaries
676List Comprehensions and Generator Expressions
228Lab: List Comprehensions and Generator Expressions
336Working with Collections and Iterables
210Lab: Working with Collections and Iterables
254Introduction to Functions in Python
235Lab: Converting Celsius to Fahrenheit
245Default Arguments and Variable Length Arguments
287Lab: Create a Function to Accept Variable Arguments & Calculate Their Average
281Introduction to Lambda Functions
244Lab: Use Lambda Functions to Filter out Odd Numbers From a List of Integers
142Importing built-in Modules
242Lab: Using the time Module to Measure Function Execution Time
224Creating Custom Modules and Packages
262Lab: Creating a Custom Module for File Operations
286Understanding Scope and Namespaces
311Lab: Experimenting with global and nonlocal in Nested Functions
364Reading from and Writing to files
241Lab: Python File Operations
484Working with Directories Using os and shutil Modules
221Lab: Python Directory Management
572Parsing Configuration Files (INI, JSON and YAML)
260Lab: Parsing Configuration Files
726Exception Handling in Python
210Lab: Exception Handling in Python
530Environment Variables
214Lab: Environment Variables
403File and Directory Operations
271Lab: File and Directory Operations
457System Specific Parameters and Functions
201Lab: System Specific Parameters and Functions
238Lab: Executing Shell Commands
179Running External Commands and Capturing Output
207Lab: Running External Commands and Capturing Output
283Error Handling in Subprocesses
176Lab: Error Handling in Subprocesses
177Introduction to sockets Module
174Lab: Resolve a Domain Name
149Creating TCP UDP Clients and Servers
113Lab: Build a Simple TCP echo Server
313Lab: Create a UDP Chat Application
299Web Requests and APIs
68Consuming RESTful APIs
76Handling JSON and XML Data
81Lab: API Interaction Fetching Weather Data with Python
481Basic Knowledge of Linux: Familiarity with Linux operating systems and command-line interface
Understanding of DevOps Concepts: Basic awareness of DevOps practices and tools
Prior Programming Experience (Beneficial but Not Required): Some experience with programming concepts can be helpful
Access to a Linux System: A computer running a Linux distribution to install Python and other tools
Text Editor or IDE: Tools like VSCode or Vim installed for writing and editing code
Internet Connection: For downloading software, accessing online resources, and working with cloud services
Configure Python environments on Linux systems, using editors like VSCode or Vim, and manage virtual environments effectively
Write Python scripts using fundamental syntax, data types, control structures, and data structures like lists and dictionaries
Automate system tasks with Python, including file handling, text processing with regular expressions, and OS interactions
Apply Python in DevOps workflows to automate Git operations, manage CI/CD pipelines, and interact with tools like Ansible, Docker, and Kubernetes