万本电子书0元读

万本电子书0元读

顶部广告

Learning Ansible 2.7电子书

售       价:¥

9人正在读 | 0人评论 9.8

作       者:Fabio Alessandro Locati

出  版  社:Packt Publishing

出版时间:2019-04-30

字       数:31.1万

所属分类: 进口书 > 外文原版书 > 电脑/网络

温馨提示:数字商品不支持退换货,不提供源文件,不支持导出打印

为你推荐

  • 读书简介
  • 目录
  • 累计评论(0条)
  • 读书简介
  • 目录
  • 累计评论(0条)
Use Ansible to configure your systems, deploy software, and orchestrate advanced IT tasks Key Features * Get familiar with the fundamentals of Ansible 2.7 * Understand how to use Ansible Tower to scale your IT automation * Gain insights into how to develop and test Ansible playbooks Book Description Ansible is an open source automation platform that assists organizations with tasks such as application deployment, orchestration, and task automation. With the release of Ansible 2.7, even complex tasks can be handled much more easily than before. Learning Ansible 2.7 will help you take your first steps toward understanding the fundamentals and practical aspects of Ansible by introducing you to topics such as playbooks, modules, and the installation of Linux, Berkeley Software Distribution (BSD), and Windows support. In addition to this, you will focus on various testing strategies, deployment, and orchestration to build on your knowledge. The book will then help you get accustomed to features including cleaner architecture, task blocks, and playbook parsing, which can help you to streamline automation processes. Next, you will learn how to integrate Ansible with cloud platforms such as Amazon Web Services (AWS) before gaining insights into the enterprise versions of Ansible, Ansible Tower and Ansible Galaxy. This will help you to use Ansible to interact with different operating systems and improve your working efficiency. By the end of this book, you will be equipped with the Ansible skills you need to automate complex tasks for your organization. What you will learn * Create a web server using Ansible * Write a custom module and test it * Deploy playbooks in the production environment * Troubleshoot networks using Ansible * Use Ansible Galaxy and Ansible Tower during deployment * Deploy an application with Ansible on AWS, Azure and DigitalOcean Who this book is for This beginner-level book is for system administrators who want to automate their organization's infrastructure using Ansible 2.7. No prior knowledge of Ansible is required
目录展开

About Packt

Why subscribe?

Packt.com

Contributors

About the author

About the reviewer

Packt is searching for authors like you

Preface

Who this book is for

What this book covers

To get the most out of this book

Download the example code files

Conventions used

Get in touch

Reviews

Section 1: Creating a Web Server Using Ansible

Getting Started with Ansible

Technical requirements

IT automation

Advantages of IT automation

Disadvantages of IT automation

Types of IT automation

Agent-based systems

Agent-less systems

Agent-based versus agent-less systems

What is Ansible?

Secure Shell

Why Ansible?

Installing Ansible

Installing Ansible using the system's package manager

Installing via Yum

Installing via Apt

Installing via Homebrew

Installing via pip

Installing Ansible from source

Creating a test environment with Vagrant

Version control systems

Using Ansible with Git

Summary

Automating Simple Tasks

Technical Requirement

YAML

Hello Ansible

Working with playbooks

Studying the anatomy of a playbook

Running a playbook

Ansible verbosity

Variables in playbooks

Creating the Ansible user

Configuring a basic server

Enabling EPEL

Installing Python bindings for SELinux

Upgrading all installed packages

Ensuring that NTP is installed, configured, and running

Ensuring that FirewallD is present and enabled

Adding a customized MOTD

Changing the hostname

Reviewing and running the playbook

Installing and configuring a web server

Publishing a website

Jinja2 templates

Variables

Filters

Conditionals

Cycles

Summary

Section 2: Deploying Playbooks in a Production Environment

Scaling to Multiple Hosts

Technical requirements

Working with inventory files

The basic inventory file

Groups in an inventory file

Regular expressions in the inventory file

Working with variables

Host variables

Group variables

Variable files

Overriding configuration parameters with an inventory file

Working with dynamic inventories

Amazon Web Services

DigitalOcean

Working with iterates in Ansible

Using standard iteration – with_items

Using nested loops – with_nested

Fileglobs loop – with_fileglobs

Using an integer loop – with_sequence

Summary

Handling Complex Deployment

Technical requirements

Working with the local_action feature

Delegating a task

Working with conditionals

Boolean conditionals

Checking whether a variable is set

Working with include

Working with handlers

Working with roles

Organizing a project

Anatomy of a role

Transforming your playbooks in a full Ansible project

Transforming a playbook into a role

Helper files

Transforming the webserver role

Handlers in roles

Execution strategies

The Ansible template – Jinja filters

Formatting data using filters

Defaulting undefined variables

Security management

Using Ansible Vault

Vaults and playbooks

Encrypting user passwords

Hiding passwords

Using no_log

Summary

Going Cloud

Technical requirements

Provisioning resources in the cloud

Provisioning machines in AWS

AWS global infrastructure

AWS Simple Storage Service

AWS Elastic Compute Cloud

AWS Virtual Private Cloud

AWS Route 53

AWS Elastic Block Storage

AWS Identity and Access Management

Amazon Relational Database Service

Setting up an account with AWS

Simple AWS deployment

Complex AWS deployment

Provisioning machines in DigitalOcean

Droplets

SSH key management

Private networking

Adding an SSH key in DigitalOcean

Deployment in DigitalOcean

Provisioning machines in Azure

Summary

Getting Notification from Ansible

Technical requirements

Sending emails with Ansible

XMPP

Slack

Rocket Chat

Internet Relay Chat

Amazon Simple Notification Service

Nagios

Summary

Section 3: Deploying an Application with Ansible

Creating a Custom Module

Prerequisite

Using Python to write modules

Working with exit_json and fail_json

Testing Python modules

Using bash modules

Using Ruby modules

Testing modules

Summary

Debugging and Error Handling

Technical requirements

Syntax checking

The check mode

Indicating differences between files using --diff

Functional testing in Ansible

Functional testing using assert

Testing with tags

Understanding the --skip-tags option

Understanding debugging commands

Managing exceptions

Trigger failure

Summary

Complex Environments

Technical requirements

Code based on the Git branch

A single stable branch with multiple folders

Software distribution strategy

Copying files from the local machine

Revision control system with branches

Revision control system with tags

RPM packages

Preparing the environment

Deploying a web app with a revision control system

Deploying a web app with RPM packages

Creating a SPEC file

Building RPMs manually

Building RPMs with Ansible

Building RPMs with CI/CD pipelines

Building compiled software with RPM packaging

Deployment strategies

Canary deployment

Blue/green deployment

Optimizations

Pipelining

Optimizing with_items

Understanding what happens when your tasks are executed

Summary

Section 4: Deploying an Application with Ansible

Introducing Ansible for Enterprises

Technical requirements

Ansible on Windows

Ansible Galaxy

Pushing a role to Ansible Galaxy

Ansible Tower and AWX

Summary

Getting Started with AWX

Technical requirements

Setting up AWX

Installing Ansible, Docker, and Docker-py in Fedora

Giving the current user permission to use Docker in Fedora

Installing AWX

Creating new AWX projects

Using AWX inventories

Understanding AWX job templates

Using AWX jobs

Summary

Working with AWX Users, Permissions, and Organizations

Technical requirements

AWX users and permissions

AWX organizations

Summary

Other Books You May Enjoy

Leave a review - let other readers know what you think

累计评论(0条) 0个书友正在讨论这本书 发表评论

发表评论

发表评论,分享你的想法吧!

买过这本书的人还买过

读了这本书的人还在读

回顶部