Description

Book Synopsis
Take advantage of Python to automate complex systems with readable code. This new edition will help you move from operations/system administration into easy-to-learn coding.

You''ll start by writing command-line scripts and automating simple DevOps-style tasks followed by creating reliable and fast unit tests designed to avoid incidents caused by buggy automation. You''ll then move on to more advanced cases, like using Jupyter as an auditable remote-control panel and writing Ansible and Salt extensions.

The updated information in this book covers best practices for deploying and updating Python applications. This includes Docker, modern Python packaging, and internal Python package repositories. You''ll also see how to use the AWS API, and the Kubernetes API, and how to automate Docker container image building and running. Finally, you''ll work with Terraform from Python to allow more flexible templating and custom

Table of Contents

Chapter 1 (Installing Python)

Different ways to install Python:

• Compiling from source

• OS packages

• pyenv

Chapter 2 (Packaging) (31 pages – 11 new pages)

How pip works and how to build packages.

The following sections need to change

Section about pip (adds 4 pages)

• Add explanation about how the resolver works

• Explain pip-compile

Poetry and pipenv (changes 2 pages, adds 2 pages)

• Needs to be separated into two sections

• Poetry section updated to reflect changes in Poetry

• Pipenv section updated to reflect changes in Pipenv

4setup.py and wheel (rewritten, changes 1 page, adds 2 pages)

• python -m build and setup.cfg

• Add details about binary wheels and manylinux

• Show a complete example

Chapter 3: Interactive usage

How to use the interactive interpreter, other text-mode interactive consoles, and Jupyter.

Chapter 4: OS Automation (16 pages – 4 new pages)

Automating OS-related things like files and processes.

Section about files (2 pages added)

• Cover using struct to parse binary data

• Cover pathlib

New section: low-level networking (2 pages) Cover socket, socket options, and how it relates

to TCP networking.

5 Chapter 5: Testing (30 pages – 10 new pages)

Writing unit tests for DevOps code.

Section about testing files (4 pages added)

• Improve performance of file testing using tmpfs and preloading libraries

• Add information about temporary directory context manager

Section about testing networking (4 pages added)

• Show how to test httpx with the WSGI support

• Show how to test low-level socket networking with DI

Section about testing processes (2 pages changed)

• Mention run and Popen

• Show how to write tests with DI on run and Popen

6 Chapter 6: Text manipulation

How to work with text: searching, modifiying, formatting, etc.

Chapter 7: Requests -> httpx (rewritten – 10 new pages)

• Focus on httpx instead

• Cover async usage

Chapter 8: Cryptography

Symmetric and asymmetric encryption and digital signatures, and how to use them in DevOps

code.

Chapter 9: Paramiko

Using paramiko to automate SSH use.

Chapter 10: Salt Stack

Using salt stack and writing new modules.

Chapter 11: Ansible

Using ansible and writing new modules.

Chapter 12: Docker (5 new pages)

• Clean up examples – they are hard to read

• Show complete example of layering, not just talk in theory

• Show complete example of running, not just talk in theory

• Add section about how to build containers for Python applications

Chapter 13: AWS

Automating AWS using the boto3 library.

New: Chapter 14: Kubernetes (10 pages)

Chapter goal: Learn how to automate k8s with Python and how to run Python applications on k8s

• Packaging Python applications for kubernetes

– Using secrets

– Thinking in Pods

• Automating k8s from Python using the REST API

• Writing k8s operators with Python

New: Chapter 15: Terraform (5 pages)

• Using the Terraform Python CDK

• Generating Terraform JSON from Python

DevOps in Python

    Product form

    £46.74

    Includes FREE delivery

    RRP £54.99 – you save £8.25 (15%)

    Order before 4pm today for delivery by Sat 27 Jun 2026.

    A Paperback / softback by Moshe Zadka

    3 in stock

      Trusted by thousands of customers. See 2,385+ Customer Reviews

      View other formats and editions of DevOps in Python by Moshe Zadka

      Publisher: APress
      Publication Date: 30/06/2022
      ISBN13: 9781484279953, 978-1484279953
      ISBN10: 1484279956

      Description

      Book Synopsis
      Take advantage of Python to automate complex systems with readable code. This new edition will help you move from operations/system administration into easy-to-learn coding.

      You''ll start by writing command-line scripts and automating simple DevOps-style tasks followed by creating reliable and fast unit tests designed to avoid incidents caused by buggy automation. You''ll then move on to more advanced cases, like using Jupyter as an auditable remote-control panel and writing Ansible and Salt extensions.

      The updated information in this book covers best practices for deploying and updating Python applications. This includes Docker, modern Python packaging, and internal Python package repositories. You''ll also see how to use the AWS API, and the Kubernetes API, and how to automate Docker container image building and running. Finally, you''ll work with Terraform from Python to allow more flexible templating and custom

      Table of Contents

      Chapter 1 (Installing Python)

      Different ways to install Python:

      • Compiling from source

      • OS packages

      • pyenv

      Chapter 2 (Packaging) (31 pages – 11 new pages)

      How pip works and how to build packages.

      The following sections need to change

      Section about pip (adds 4 pages)

      • Add explanation about how the resolver works

      • Explain pip-compile

      Poetry and pipenv (changes 2 pages, adds 2 pages)

      • Needs to be separated into two sections

      • Poetry section updated to reflect changes in Poetry

      • Pipenv section updated to reflect changes in Pipenv

      4setup.py and wheel (rewritten, changes 1 page, adds 2 pages)

      • python -m build and setup.cfg

      • Add details about binary wheels and manylinux

      • Show a complete example

      Chapter 3: Interactive usage

      How to use the interactive interpreter, other text-mode interactive consoles, and Jupyter.

      Chapter 4: OS Automation (16 pages – 4 new pages)

      Automating OS-related things like files and processes.

      Section about files (2 pages added)

      • Cover using struct to parse binary data

      • Cover pathlib

      New section: low-level networking (2 pages) Cover socket, socket options, and how it relates

      to TCP networking.

      5 Chapter 5: Testing (30 pages – 10 new pages)

      Writing unit tests for DevOps code.

      Section about testing files (4 pages added)

      • Improve performance of file testing using tmpfs and preloading libraries

      • Add information about temporary directory context manager

      Section about testing networking (4 pages added)

      • Show how to test httpx with the WSGI support

      • Show how to test low-level socket networking with DI

      Section about testing processes (2 pages changed)

      • Mention run and Popen

      • Show how to write tests with DI on run and Popen

      6 Chapter 6: Text manipulation

      How to work with text: searching, modifiying, formatting, etc.

      Chapter 7: Requests -> httpx (rewritten – 10 new pages)

      • Focus on httpx instead

      • Cover async usage

      Chapter 8: Cryptography

      Symmetric and asymmetric encryption and digital signatures, and how to use them in DevOps

      code.

      Chapter 9: Paramiko

      Using paramiko to automate SSH use.

      Chapter 10: Salt Stack

      Using salt stack and writing new modules.

      Chapter 11: Ansible

      Using ansible and writing new modules.

      Chapter 12: Docker (5 new pages)

      • Clean up examples – they are hard to read

      • Show complete example of layering, not just talk in theory

      • Show complete example of running, not just talk in theory

      • Add section about how to build containers for Python applications

      Chapter 13: AWS

      Automating AWS using the boto3 library.

      New: Chapter 14: Kubernetes (10 pages)

      Chapter goal: Learn how to automate k8s with Python and how to run Python applications on k8s

      • Packaging Python applications for kubernetes

      – Using secrets

      – Thinking in Pods

      • Automating k8s from Python using the REST API

      • Writing k8s operators with Python

      New: Chapter 15: Terraform (5 pages)

      • Using the Terraform Python CDK

      • Generating Terraform JSON from Python

      Recently viewed products

      © 2026 Book Curl

        • American Express
        • Apple Pay
        • Diners Club
        • Discover
        • Google Pay
        • Maestro
        • Mastercard
        • PayPal
        • Shop Pay
        • Union Pay
        • Visa

        Login

        Forgot your password?

        Don't have an account yet?
        Create account