SlideShare a Scribd company logo
1 of 20
Download to read offline
Daniel Fienberg
DevOps Engineer
danielfi@cloudzone.io
Ansible on AWS
• Open source configuration management platform written in Python
and backed by software giant RedHat
• Salt, Chef, Puppet are other CM platforms
• Scripting on a high level
• Designed to be centralized, lightweight, scalable, fast, easy to
install and use
• Used for any task that you need to do more than once
• Playbooks (Ansible scripts) written in YAML
• No agent required on target hosts
What is Ansible?
How Ansible is Different
from Other CM Platforms
Ansible Other CM Platforms
(Chef, Puppet, Salt)
SSH (22)
Control
Node
Remote Hosts
CM Agent
Control
Node
• Ansible performs tasks on hosts and calls modules to
perform them
• Ansible runs through its tasks on a set of hosts in parallel
• Modules provide wrappers for tasks
• Tasks make changes only if necessary
• Core set of modules for common SysAdmin tasks
(package maintenance, filesystem maintenance etc.)
• Modules for shell commands and scripts
How does Ansible Work?
• Many cloud modules come built-in
• Can be run as a local action and perform the action from your
laptop
• Covers most common cloud tasks.

ec2 - create, terminate, start or stop an instance in ec2

ec2_ami - create or destroy an image in ec2

ec2_ami_search - Retrieve AWS AMI information for a given operating system.

ec2_asg - Create or delete AWS Autoscaling Groups

ec2_eip - associate an EC2 elastic IP with an instance.

ec2_elb - De-registers or registers instances from EC2 ELBs

ec2_facts - Gathers facts about remote hosts within ec2 (aws)

ec2_group - maintain an ec2 VPC security group.

ec2_key - maintain an ec2 key pair.

ec2_vol - create and attach a volume, return volume id and device map

… and many more)
AWS Cloud Modules
How Cloud Modules Work
Regular Module
Python Script Sent over SSH
e.g. Install Apache
AWS Cloud Module
Control Node
Control Node
Amazon API
Boto
Provision AWS Service e.g. Add EBS
Remote Host
Local
Action
Remote Host
• Ansible needs to know where to run commands
• This information is found in an inventory file
• It can be static and manually maintained

localhost ansible_connection=local <——-> Host

[webservers] <——-> Group

10.10.10.10 ansible_user=ec2-user ansible_ssh_private_key_file=~/.ssh/aws.pem

10.10.10.20

[dbservers]

one.example.com
• You can include many extra details in inventory file - tags,
SSH keys, aliases, login user etc.
Inventory File
• Inventory file that is generated automatically at runtime by
a script
• Ansible knows to run the inventory file as a script because
of executable permissions on the file
• Useful for cloud environments because hosts and their
addresses change often
• Script makes API calls to cloud provider and uses
information to generate inventory file
• Scripts for AWS, OpenStack etc on Ansible Github repo
Dynamic Inventory
• Defines each host as a JSON object
• Public or private IP used as host identifier (ec2.ini)
• Groups hosts according to many filters (instance
type, tags, security groups, AZs)
• EC2 instance details can be referenced at runtime
(e.g. tags, instance type, private key name etc.)
AWS Dynamic Inventory
• Extremely powerful Ansible module (setup) that is
optionally run at the beginning of a Playbook
• Gathers LOTS of information about the host that can
be accessed by Playbook at runtime
• Variables defined by facts can be referenced at run
time by the Playbook
• Useful for provisioning systems based on conditions
(OS, kernel, volumes, network interfaces etc.)
Get Facts
• Ansible can either be run as an ad-hoc command
or as script called a Playbook (YAML format)
• Ad-hoc command is for one time command on
many servers
• Ad-hoc Command Usage:

# ansible <host-pattern> -m <module> -
a <arguments> -i inventory [options]
Ad-hoc Command
• Ansible ping

# ansible all -m ping -i static
• Ansible facts

# ansible tag_Name_dev -m setup -i ec2.py --private-key
=~/.ssh/private_key.pem -u ec2-user
• EC2 facts

# ansible tag_Name_dev -m ec2_facts -i ec2.py -u ec2-user —
private-key=“{{ ec2_key_name }}.pem”
• Install apache

# ansible webservers -m yum -a "name=httpd state=present” -i
static
Ad-hoc Command Examples
• The real power of Ansible are Playbooks
• Easily readable set of tasks to perform
• Include files for easy grouping of tasks
• Only perform tasks on based on instance specific info
(AWS instance tags, AWS instance type, OS type, etc.)
• Playbook Command Usage:

# ansible-playbook playbook.yml -i
inventory [options]
Playbooks
• Comprehensive documentation on Ansible website
• Example playbooks on Ansible Github repo
• Ansible Galaxy - community repo of Playbooks
(galaxy.ansible.com)
• Ansible Tower - Commercial visual dashboard
Getting Started
• Released at beginning of 2016
• Introduced code blocks
• Try-catch statements
• Extended support for Windows (winrm)
• Many more cloud modules
Ansible 2.0
1. Provision instances in AWS environment
2. Apply AWS configurations (Security Groups etc.)
3. Install LAMP services
4. Copy custom configuration files, set services to on
etc.
Provision LAMP Stack
• There isn’t time to do things manually if you want to
remain profitable
• Tasks that you thought were not easy to automate
often are
• Ansible does not make mistakes - people do!
• Can prepare environment for Ansible with a
wrapper script
Tip 1: Be Lazy
• All configuration done with SSH
• All key locations are passed as a dynamically
generated path
• Boto credentials are set as environment variables
with a wrapper script
• No sensitive data ever included in playbook -
customer specific data stored at a separate
location
Tip 2: Be Secure
• Write playbooks that can run on many OSs
• Automatically detect login user name
• Use templates, dynamic inventory variables and
Ansible facts
• Dynamically locate customer specific variables
Tip 3: Be Dynamic
Thank you!
By the way, we’re hiring:

Cloud engineers and DevOps

contact@cloudzone.io

More Related Content

What's hot

Containerd - core container runtime component
Containerd - core container runtime component Containerd - core container runtime component
Containerd - core container runtime component Docker, Inc.
 
Looking Under The Hood: containerD
Looking Under The Hood: containerDLooking Under The Hood: containerD
Looking Under The Hood: containerDDocker, Inc.
 
Persistent Data Storage for Docker Containers by Andre Moruga
Persistent Data Storage for Docker Containers by Andre MorugaPersistent Data Storage for Docker Containers by Andre Moruga
Persistent Data Storage for Docker Containers by Andre MorugaDocker, Inc.
 
Kubernetes and OpenStack at Scale
Kubernetes and OpenStack at ScaleKubernetes and OpenStack at Scale
Kubernetes and OpenStack at ScaleStephen Gordon
 
DockerDay2015: Docker orchestration for sysadmin
DockerDay2015: Docker orchestration for sysadminDockerDay2015: Docker orchestration for sysadmin
DockerDay2015: Docker orchestration for sysadminDocker-Hanoi
 
A Closer Look at Kubernetes Pods and Replica Sets
A Closer Look at Kubernetes Pods and Replica SetsA Closer Look at Kubernetes Pods and Replica Sets
A Closer Look at Kubernetes Pods and Replica SetsJanakiram MSV
 
Containers #101 : Docker ONBUILD triggers and Introduction to Docker Compose
Containers #101 : Docker ONBUILD triggers and Introduction to Docker ComposeContainers #101 : Docker ONBUILD triggers and Introduction to Docker Compose
Containers #101 : Docker ONBUILD triggers and Introduction to Docker ComposeRaziel Tabib (Join our team)
 
DockerCon EU 2015: Placing a container on a train at 200mph
DockerCon EU 2015: Placing a container on a train at 200mphDockerCon EU 2015: Placing a container on a train at 200mph
DockerCon EU 2015: Placing a container on a train at 200mphDocker, Inc.
 
IPC16: A Practical Introduction to Kubernetes
IPC16: A Practical Introduction to Kubernetes IPC16: A Practical Introduction to Kubernetes
IPC16: A Practical Introduction to Kubernetes Robert Lemke
 
Understanding the Docker ecosystem
Understanding the Docker ecosystemUnderstanding the Docker ecosystem
Understanding the Docker ecosystemKiratech
 
Docker for PHP Developers - Jetbrains
Docker for PHP Developers - JetbrainsDocker for PHP Developers - Jetbrains
Docker for PHP Developers - JetbrainsChris Tankersley
 
Kubernetes fundamentals
Kubernetes fundamentalsKubernetes fundamentals
Kubernetes fundamentalsVictor Morales
 
OSCON: System software goes weird
OSCON: System software goes weirdOSCON: System software goes weird
OSCON: System software goes weirdDocker, Inc.
 
Docker Engine Evolution: From Monolith to Discrete Components
Docker Engine Evolution: From Monolith to Discrete ComponentsDocker Engine Evolution: From Monolith to Discrete Components
Docker Engine Evolution: From Monolith to Discrete ComponentsPhil Estes
 

What's hot (20)

Fabric8 CI/CD
Fabric8 CI/CDFabric8 CI/CD
Fabric8 CI/CD
 
Containerd - core container runtime component
Containerd - core container runtime component Containerd - core container runtime component
Containerd - core container runtime component
 
Looking Under The Hood: containerD
Looking Under The Hood: containerDLooking Under The Hood: containerD
Looking Under The Hood: containerD
 
Containers and HPC
Containers and HPCContainers and HPC
Containers and HPC
 
Persistent Data Storage for Docker Containers by Andre Moruga
Persistent Data Storage for Docker Containers by Andre MorugaPersistent Data Storage for Docker Containers by Andre Moruga
Persistent Data Storage for Docker Containers by Andre Moruga
 
OpenStack Kolla project update rocky release
OpenStack Kolla project update rocky releaseOpenStack Kolla project update rocky release
OpenStack Kolla project update rocky release
 
Docker on Docker
Docker on DockerDocker on Docker
Docker on Docker
 
LinuxKit
LinuxKitLinuxKit
LinuxKit
 
Kubernetes and OpenStack at Scale
Kubernetes and OpenStack at ScaleKubernetes and OpenStack at Scale
Kubernetes and OpenStack at Scale
 
DockerDay2015: Docker orchestration for sysadmin
DockerDay2015: Docker orchestration for sysadminDockerDay2015: Docker orchestration for sysadmin
DockerDay2015: Docker orchestration for sysadmin
 
Project Moby
Project MobyProject Moby
Project Moby
 
A Closer Look at Kubernetes Pods and Replica Sets
A Closer Look at Kubernetes Pods and Replica SetsA Closer Look at Kubernetes Pods and Replica Sets
A Closer Look at Kubernetes Pods and Replica Sets
 
Containers #101 : Docker ONBUILD triggers and Introduction to Docker Compose
Containers #101 : Docker ONBUILD triggers and Introduction to Docker ComposeContainers #101 : Docker ONBUILD triggers and Introduction to Docker Compose
Containers #101 : Docker ONBUILD triggers and Introduction to Docker Compose
 
DockerCon EU 2015: Placing a container on a train at 200mph
DockerCon EU 2015: Placing a container on a train at 200mphDockerCon EU 2015: Placing a container on a train at 200mph
DockerCon EU 2015: Placing a container on a train at 200mph
 
IPC16: A Practical Introduction to Kubernetes
IPC16: A Practical Introduction to Kubernetes IPC16: A Practical Introduction to Kubernetes
IPC16: A Practical Introduction to Kubernetes
 
Understanding the Docker ecosystem
Understanding the Docker ecosystemUnderstanding the Docker ecosystem
Understanding the Docker ecosystem
 
Docker for PHP Developers - Jetbrains
Docker for PHP Developers - JetbrainsDocker for PHP Developers - Jetbrains
Docker for PHP Developers - Jetbrains
 
Kubernetes fundamentals
Kubernetes fundamentalsKubernetes fundamentals
Kubernetes fundamentals
 
OSCON: System software goes weird
OSCON: System software goes weirdOSCON: System software goes weird
OSCON: System software goes weird
 
Docker Engine Evolution: From Monolith to Discrete Components
Docker Engine Evolution: From Monolith to Discrete ComponentsDocker Engine Evolution: From Monolith to Discrete Components
Docker Engine Evolution: From Monolith to Discrete Components
 

Viewers also liked

A Dive Into Containers and Docker
A Dive Into Containers and DockerA Dive Into Containers and Docker
A Dive Into Containers and DockerMatthew Farina
 
Rise of the Machines - Automate your Development
Rise of the Machines - Automate your DevelopmentRise of the Machines - Automate your Development
Rise of the Machines - Automate your DevelopmentSven Peters
 
Jenkins Docker
Jenkins DockerJenkins Docker
Jenkins DockerAlex Soto
 
Ic maven jenkins_sonar
Ic maven jenkins_sonarIc maven jenkins_sonar
Ic maven jenkins_sonarRocío Muñoz
 
Dockercon2015 bamboo
Dockercon2015 bambooDockercon2015 bamboo
Dockercon2015 bambooSteve Smith
 
Game of Codes: the Battle for CI
Game of Codes: the Battle for CIGame of Codes: the Battle for CI
Game of Codes: the Battle for CIAtlassian
 
Master Continuous Delivery with CloudBees Jenkins Platform
Master Continuous Delivery with CloudBees Jenkins PlatformMaster Continuous Delivery with CloudBees Jenkins Platform
Master Continuous Delivery with CloudBees Jenkins Platformdcjuengst
 
GitFlow, SourceTree and GitLab
GitFlow, SourceTree and GitLabGitFlow, SourceTree and GitLab
GitFlow, SourceTree and GitLabShinu Suresh
 
Getting started with Jenkins
Getting started with JenkinsGetting started with Jenkins
Getting started with JenkinsEdureka!
 
Ansible is the simplest way to automate. MoldCamp, 2015
Ansible is the simplest way to automate. MoldCamp, 2015Ansible is the simplest way to automate. MoldCamp, 2015
Ansible is the simplest way to automate. MoldCamp, 2015Alex S
 
Bamboo - an introduction
Bamboo - an introductionBamboo - an introduction
Bamboo - an introductionSven Peters
 
Using Docker for Testing
Using Docker for TestingUsing Docker for Testing
Using Docker for TestingCarlos Sanchez
 
Gitlab Training with GIT and SourceTree
Gitlab Training with GIT and SourceTreeGitlab Training with GIT and SourceTree
Gitlab Training with GIT and SourceTreeTeerapat Khunpech
 
Git and GitHub for Documentation
Git and GitHub for DocumentationGit and GitHub for Documentation
Git and GitHub for DocumentationAnne Gentle
 
Continuous Delivery with Jenkins and Wildfly (2014)
Continuous Delivery with Jenkins and Wildfly (2014)Continuous Delivery with Jenkins and Wildfly (2014)
Continuous Delivery with Jenkins and Wildfly (2014)Tracy Kennedy
 
Git 101 - Crash Course in Version Control using Git
Git 101 - Crash Course in Version Control using GitGit 101 - Crash Course in Version Control using Git
Git 101 - Crash Course in Version Control using GitGeoff Hoffman
 
Introduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guideIntroduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guideRohit Arora
 

Viewers also liked (20)

DevOps @ OpenShift Online
DevOps @ OpenShift OnlineDevOps @ OpenShift Online
DevOps @ OpenShift Online
 
A Dive Into Containers and Docker
A Dive Into Containers and DockerA Dive Into Containers and Docker
A Dive Into Containers and Docker
 
Ansible
AnsibleAnsible
Ansible
 
Rise of the Machines - Automate your Development
Rise of the Machines - Automate your DevelopmentRise of the Machines - Automate your Development
Rise of the Machines - Automate your Development
 
Jenkins Docker
Jenkins DockerJenkins Docker
Jenkins Docker
 
Ic maven jenkins_sonar
Ic maven jenkins_sonarIc maven jenkins_sonar
Ic maven jenkins_sonar
 
Dockercon2015 bamboo
Dockercon2015 bambooDockercon2015 bamboo
Dockercon2015 bamboo
 
Game of Codes: the Battle for CI
Game of Codes: the Battle for CIGame of Codes: the Battle for CI
Game of Codes: the Battle for CI
 
Master Continuous Delivery with CloudBees Jenkins Platform
Master Continuous Delivery with CloudBees Jenkins PlatformMaster Continuous Delivery with CloudBees Jenkins Platform
Master Continuous Delivery with CloudBees Jenkins Platform
 
GitFlow, SourceTree and GitLab
GitFlow, SourceTree and GitLabGitFlow, SourceTree and GitLab
GitFlow, SourceTree and GitLab
 
Getting started with Jenkins
Getting started with JenkinsGetting started with Jenkins
Getting started with Jenkins
 
Ansible is the simplest way to automate. MoldCamp, 2015
Ansible is the simplest way to automate. MoldCamp, 2015Ansible is the simplest way to automate. MoldCamp, 2015
Ansible is the simplest way to automate. MoldCamp, 2015
 
Bamboo - an introduction
Bamboo - an introductionBamboo - an introduction
Bamboo - an introduction
 
Using Docker for Testing
Using Docker for TestingUsing Docker for Testing
Using Docker for Testing
 
Gitlab Training with GIT and SourceTree
Gitlab Training with GIT and SourceTreeGitlab Training with GIT and SourceTree
Gitlab Training with GIT and SourceTree
 
Git and GitHub for Documentation
Git and GitHub for DocumentationGit and GitHub for Documentation
Git and GitHub for Documentation
 
Continuous Delivery with Jenkins and Wildfly (2014)
Continuous Delivery with Jenkins and Wildfly (2014)Continuous Delivery with Jenkins and Wildfly (2014)
Continuous Delivery with Jenkins and Wildfly (2014)
 
Git best practices workshop
Git best practices workshopGit best practices workshop
Git best practices workshop
 
Git 101 - Crash Course in Version Control using Git
Git 101 - Crash Course in Version Control using GitGit 101 - Crash Course in Version Control using Git
Git 101 - Crash Course in Version Control using Git
 
Introduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guideIntroduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guide
 

Similar to Ansible 2.0 - How to use Ansible to automate your applications in AWS.

Go Faster with Ansible (AWS meetup)
Go Faster with Ansible (AWS meetup)Go Faster with Ansible (AWS meetup)
Go Faster with Ansible (AWS meetup)Richard Donkin
 
Ansible Tutorial.pdf
Ansible Tutorial.pdfAnsible Tutorial.pdf
Ansible Tutorial.pdfNigussMehari4
 
Go Faster with Ansible (PHP meetup)
Go Faster with Ansible (PHP meetup)Go Faster with Ansible (PHP meetup)
Go Faster with Ansible (PHP meetup)Richard Donkin
 
RTP NPUG: Ansible Intro and Integration with ACI
RTP NPUG: Ansible Intro and Integration with ACIRTP NPUG: Ansible Intro and Integration with ACI
RTP NPUG: Ansible Intro and Integration with ACIJoel W. King
 
Ansible 101 - Presentation at Ansible STL Meetup
Ansible 101 - Presentation at Ansible STL MeetupAnsible 101 - Presentation at Ansible STL Meetup
Ansible 101 - Presentation at Ansible STL MeetupJeff Geerling
 
Ansible a tool for dev ops
Ansible a tool for dev opsAnsible a tool for dev ops
Ansible a tool for dev opsRené Ribaud
 
Ansible presentation
Ansible presentationAnsible presentation
Ansible presentationSuresh Kumar
 
Ansible & Salt - Vincent Boon
Ansible & Salt - Vincent BoonAnsible & Salt - Vincent Boon
Ansible & Salt - Vincent BoonMyNOG
 
Ansible + Amazon AWS talk installfest.cz 2016
Ansible + Amazon AWS talk installfest.cz 2016Ansible + Amazon AWS talk installfest.cz 2016
Ansible + Amazon AWS talk installfest.cz 2016David Karban
 
Automated Deployment and Configuration Engines. Ansible
Automated Deployment and Configuration Engines. AnsibleAutomated Deployment and Configuration Engines. Ansible
Automated Deployment and Configuration Engines. AnsibleAlberto Molina Coballes
 
Hyperledger Cello Feb 20, 2018
Hyperledger Cello Feb 20, 2018Hyperledger Cello Feb 20, 2018
Hyperledger Cello Feb 20, 2018Arnaud Le Hors
 
Network automation ansible_nx-api
Network automation ansible_nx-apiNetwork automation ansible_nx-api
Network automation ansible_nx-apiJoel W. King
 
Network Automation with Ansible
Network Automation with AnsibleNetwork Automation with Ansible
Network Automation with AnsibleAnas
 
Containers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshellContainers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshellEugene Fedorenko
 
PowerPoint Presentation
PowerPoint PresentationPowerPoint Presentation
PowerPoint Presentationlalitjangra9
 

Similar to Ansible 2.0 - How to use Ansible to automate your applications in AWS. (20)

Ansible - Hands on Training
Ansible - Hands on TrainingAnsible - Hands on Training
Ansible - Hands on Training
 
Go Faster with Ansible (AWS meetup)
Go Faster with Ansible (AWS meetup)Go Faster with Ansible (AWS meetup)
Go Faster with Ansible (AWS meetup)
 
Ansible Tutorial.pdf
Ansible Tutorial.pdfAnsible Tutorial.pdf
Ansible Tutorial.pdf
 
Go Faster with Ansible (PHP meetup)
Go Faster with Ansible (PHP meetup)Go Faster with Ansible (PHP meetup)
Go Faster with Ansible (PHP meetup)
 
RTP NPUG: Ansible Intro and Integration with ACI
RTP NPUG: Ansible Intro and Integration with ACIRTP NPUG: Ansible Intro and Integration with ACI
RTP NPUG: Ansible Intro and Integration with ACI
 
Ansible 101 - Presentation at Ansible STL Meetup
Ansible 101 - Presentation at Ansible STL MeetupAnsible 101 - Presentation at Ansible STL Meetup
Ansible 101 - Presentation at Ansible STL Meetup
 
DevOps for database
DevOps for databaseDevOps for database
DevOps for database
 
Ansible get started
Ansible get startedAnsible get started
Ansible get started
 
Ansible a tool for dev ops
Ansible a tool for dev opsAnsible a tool for dev ops
Ansible a tool for dev ops
 
Ansible presentation
Ansible presentationAnsible presentation
Ansible presentation
 
Kubernetes
KubernetesKubernetes
Kubernetes
 
Ansible & Salt - Vincent Boon
Ansible & Salt - Vincent BoonAnsible & Salt - Vincent Boon
Ansible & Salt - Vincent Boon
 
Ansible + Amazon AWS talk installfest.cz 2016
Ansible + Amazon AWS talk installfest.cz 2016Ansible + Amazon AWS talk installfest.cz 2016
Ansible + Amazon AWS talk installfest.cz 2016
 
Automated Deployment and Configuration Engines. Ansible
Automated Deployment and Configuration Engines. AnsibleAutomated Deployment and Configuration Engines. Ansible
Automated Deployment and Configuration Engines. Ansible
 
Hyperledger Cello Feb 20, 2018
Hyperledger Cello Feb 20, 2018Hyperledger Cello Feb 20, 2018
Hyperledger Cello Feb 20, 2018
 
Network automation ansible_nx-api
Network automation ansible_nx-apiNetwork automation ansible_nx-api
Network automation ansible_nx-api
 
Ansible intro
Ansible introAnsible intro
Ansible intro
 
Network Automation with Ansible
Network Automation with AnsibleNetwork Automation with Ansible
Network Automation with Ansible
 
Containers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshellContainers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshell
 
PowerPoint Presentation
PowerPoint PresentationPowerPoint Presentation
PowerPoint Presentation
 

More from Idan Tohami

Simplify Your Security with Cybowall
Simplify Your Security with CybowallSimplify Your Security with Cybowall
Simplify Your Security with CybowallIdan Tohami
 
AML Transaction Monitoring Tuning Webinar
AML Transaction Monitoring Tuning WebinarAML Transaction Monitoring Tuning Webinar
AML Transaction Monitoring Tuning WebinarIdan Tohami
 
Robotic Process Automation (RPA) Webinar - By Matrix-IFS
Robotic Process Automation (RPA) Webinar - By Matrix-IFSRobotic Process Automation (RPA) Webinar - By Matrix-IFS
Robotic Process Automation (RPA) Webinar - By Matrix-IFSIdan Tohami
 
Open Banking / PSD2 & GDPR Regulations and How They Are Changing Fraud & Fina...
Open Banking / PSD2 & GDPR Regulations and How They Are Changing Fraud & Fina...Open Banking / PSD2 & GDPR Regulations and How They Are Changing Fraud & Fina...
Open Banking / PSD2 & GDPR Regulations and How They Are Changing Fraud & Fina...Idan Tohami
 
Robotic Automation Process (RPA) Webinar - By Matrix-IFS
Robotic Automation Process (RPA) Webinar - By Matrix-IFSRobotic Automation Process (RPA) Webinar - By Matrix-IFS
Robotic Automation Process (RPA) Webinar - By Matrix-IFSIdan Tohami
 
Robotic Automation Process (RPA) Brochure - By Matrix-IFS
Robotic Automation Process (RPA) Brochure - By Matrix-IFSRobotic Automation Process (RPA) Brochure - By Matrix-IFS
Robotic Automation Process (RPA) Brochure - By Matrix-IFSIdan Tohami
 
The Journey to the Hybrid Multi Cloud
The Journey to the Hybrid Multi CloudThe Journey to the Hybrid Multi Cloud
The Journey to the Hybrid Multi CloudIdan Tohami
 
Introdction to Cloud Regulation for Enterprise by 2Bsecure
Introdction to Cloud Regulation for Enterprise by 2BsecureIntrodction to Cloud Regulation for Enterprise by 2Bsecure
Introdction to Cloud Regulation for Enterprise by 2BsecureIdan Tohami
 
Enterprise Journey to the Cloud - Opening Remarks
Enterprise Journey to the Cloud  - Opening RemarksEnterprise Journey to the Cloud  - Opening Remarks
Enterprise Journey to the Cloud - Opening RemarksIdan Tohami
 
Ready.Set.Cloud - Enterprise Cloud Migration Framework
Ready.Set.Cloud - Enterprise Cloud Migration FrameworkReady.Set.Cloud - Enterprise Cloud Migration Framework
Ready.Set.Cloud - Enterprise Cloud Migration FrameworkIdan Tohami
 
Journey to the Public Cloud
Journey to the Public CloudJourney to the Public Cloud
Journey to the Public CloudIdan Tohami
 
Google Cloud Fundamentals by CloudZone
Google Cloud Fundamentals by CloudZoneGoogle Cloud Fundamentals by CloudZone
Google Cloud Fundamentals by CloudZoneIdan Tohami
 
HDinsight Workshop - Prerequisite Activity
HDinsight Workshop - Prerequisite ActivityHDinsight Workshop - Prerequisite Activity
HDinsight Workshop - Prerequisite ActivityIdan Tohami
 
Cloud Regulations and Security Standards by Ran Adler
Cloud Regulations and Security Standards by Ran AdlerCloud Regulations and Security Standards by Ran Adler
Cloud Regulations and Security Standards by Ran AdlerIdan Tohami
 
Azure Logic Apps by Gil Gross, CloudZone
Azure Logic Apps by Gil Gross, CloudZoneAzure Logic Apps by Gil Gross, CloudZone
Azure Logic Apps by Gil Gross, CloudZoneIdan Tohami
 
AWS Fundamentals @Back2School by CloudZone
AWS Fundamentals @Back2School by CloudZoneAWS Fundamentals @Back2School by CloudZone
AWS Fundamentals @Back2School by CloudZoneIdan Tohami
 
Cloud Accelerated Genomics
Cloud Accelerated GenomicsCloud Accelerated Genomics
Cloud Accelerated GenomicsIdan Tohami
 
Achieving HIPAA on GCP
Achieving HIPAA on GCPAchieving HIPAA on GCP
Achieving HIPAA on GCPIdan Tohami
 

More from Idan Tohami (20)

Simplify Your Security with Cybowall
Simplify Your Security with CybowallSimplify Your Security with Cybowall
Simplify Your Security with Cybowall
 
AML Transaction Monitoring Tuning Webinar
AML Transaction Monitoring Tuning WebinarAML Transaction Monitoring Tuning Webinar
AML Transaction Monitoring Tuning Webinar
 
Robotic Process Automation (RPA) Webinar - By Matrix-IFS
Robotic Process Automation (RPA) Webinar - By Matrix-IFSRobotic Process Automation (RPA) Webinar - By Matrix-IFS
Robotic Process Automation (RPA) Webinar - By Matrix-IFS
 
Open Banking / PSD2 & GDPR Regulations and How They Are Changing Fraud & Fina...
Open Banking / PSD2 & GDPR Regulations and How They Are Changing Fraud & Fina...Open Banking / PSD2 & GDPR Regulations and How They Are Changing Fraud & Fina...
Open Banking / PSD2 & GDPR Regulations and How They Are Changing Fraud & Fina...
 
Robotic Automation Process (RPA) Webinar - By Matrix-IFS
Robotic Automation Process (RPA) Webinar - By Matrix-IFSRobotic Automation Process (RPA) Webinar - By Matrix-IFS
Robotic Automation Process (RPA) Webinar - By Matrix-IFS
 
Robotic Automation Process (RPA) Brochure - By Matrix-IFS
Robotic Automation Process (RPA) Brochure - By Matrix-IFSRobotic Automation Process (RPA) Brochure - By Matrix-IFS
Robotic Automation Process (RPA) Brochure - By Matrix-IFS
 
The Journey to the Hybrid Multi Cloud
The Journey to the Hybrid Multi CloudThe Journey to the Hybrid Multi Cloud
The Journey to the Hybrid Multi Cloud
 
Introdction to Cloud Regulation for Enterprise by 2Bsecure
Introdction to Cloud Regulation for Enterprise by 2BsecureIntrodction to Cloud Regulation for Enterprise by 2Bsecure
Introdction to Cloud Regulation for Enterprise by 2Bsecure
 
Enterprise Journey to the Cloud - Opening Remarks
Enterprise Journey to the Cloud  - Opening RemarksEnterprise Journey to the Cloud  - Opening Remarks
Enterprise Journey to the Cloud - Opening Remarks
 
Vmware on aws
Vmware on awsVmware on aws
Vmware on aws
 
Ready.Set.Cloud - Enterprise Cloud Migration Framework
Ready.Set.Cloud - Enterprise Cloud Migration FrameworkReady.Set.Cloud - Enterprise Cloud Migration Framework
Ready.Set.Cloud - Enterprise Cloud Migration Framework
 
Journey to the Public Cloud
Journey to the Public CloudJourney to the Public Cloud
Journey to the Public Cloud
 
Google Cloud Fundamentals by CloudZone
Google Cloud Fundamentals by CloudZoneGoogle Cloud Fundamentals by CloudZone
Google Cloud Fundamentals by CloudZone
 
HDinsight Workshop - Prerequisite Activity
HDinsight Workshop - Prerequisite ActivityHDinsight Workshop - Prerequisite Activity
HDinsight Workshop - Prerequisite Activity
 
Cloud Regulations and Security Standards by Ran Adler
Cloud Regulations and Security Standards by Ran AdlerCloud Regulations and Security Standards by Ran Adler
Cloud Regulations and Security Standards by Ran Adler
 
Azure Logic Apps by Gil Gross, CloudZone
Azure Logic Apps by Gil Gross, CloudZoneAzure Logic Apps by Gil Gross, CloudZone
Azure Logic Apps by Gil Gross, CloudZone
 
AWS Fundamentals @Back2School by CloudZone
AWS Fundamentals @Back2School by CloudZoneAWS Fundamentals @Back2School by CloudZone
AWS Fundamentals @Back2School by CloudZone
 
Cloud Accelerated Genomics
Cloud Accelerated GenomicsCloud Accelerated Genomics
Cloud Accelerated Genomics
 
Achieving HIPAA on GCP
Achieving HIPAA on GCPAchieving HIPAA on GCP
Achieving HIPAA on GCP
 
Couchbase Day
Couchbase DayCouchbase Day
Couchbase Day
 

Recently uploaded

Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 

Recently uploaded (20)

E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 

Ansible 2.0 - How to use Ansible to automate your applications in AWS.

  • 2. • Open source configuration management platform written in Python and backed by software giant RedHat • Salt, Chef, Puppet are other CM platforms • Scripting on a high level • Designed to be centralized, lightweight, scalable, fast, easy to install and use • Used for any task that you need to do more than once • Playbooks (Ansible scripts) written in YAML • No agent required on target hosts What is Ansible?
  • 3. How Ansible is Different from Other CM Platforms Ansible Other CM Platforms (Chef, Puppet, Salt) SSH (22) Control Node Remote Hosts CM Agent Control Node
  • 4. • Ansible performs tasks on hosts and calls modules to perform them • Ansible runs through its tasks on a set of hosts in parallel • Modules provide wrappers for tasks • Tasks make changes only if necessary • Core set of modules for common SysAdmin tasks (package maintenance, filesystem maintenance etc.) • Modules for shell commands and scripts How does Ansible Work?
  • 5. • Many cloud modules come built-in • Can be run as a local action and perform the action from your laptop • Covers most common cloud tasks.
 ec2 - create, terminate, start or stop an instance in ec2
 ec2_ami - create or destroy an image in ec2
 ec2_ami_search - Retrieve AWS AMI information for a given operating system.
 ec2_asg - Create or delete AWS Autoscaling Groups
 ec2_eip - associate an EC2 elastic IP with an instance.
 ec2_elb - De-registers or registers instances from EC2 ELBs
 ec2_facts - Gathers facts about remote hosts within ec2 (aws)
 ec2_group - maintain an ec2 VPC security group.
 ec2_key - maintain an ec2 key pair.
 ec2_vol - create and attach a volume, return volume id and device map
 … and many more) AWS Cloud Modules
  • 6. How Cloud Modules Work Regular Module Python Script Sent over SSH e.g. Install Apache AWS Cloud Module Control Node Control Node Amazon API Boto Provision AWS Service e.g. Add EBS Remote Host Local Action Remote Host
  • 7. • Ansible needs to know where to run commands • This information is found in an inventory file • It can be static and manually maintained
 localhost ansible_connection=local <——-> Host
 [webservers] <——-> Group
 10.10.10.10 ansible_user=ec2-user ansible_ssh_private_key_file=~/.ssh/aws.pem
 10.10.10.20
 [dbservers]
 one.example.com • You can include many extra details in inventory file - tags, SSH keys, aliases, login user etc. Inventory File
  • 8. • Inventory file that is generated automatically at runtime by a script • Ansible knows to run the inventory file as a script because of executable permissions on the file • Useful for cloud environments because hosts and their addresses change often • Script makes API calls to cloud provider and uses information to generate inventory file • Scripts for AWS, OpenStack etc on Ansible Github repo Dynamic Inventory
  • 9. • Defines each host as a JSON object • Public or private IP used as host identifier (ec2.ini) • Groups hosts according to many filters (instance type, tags, security groups, AZs) • EC2 instance details can be referenced at runtime (e.g. tags, instance type, private key name etc.) AWS Dynamic Inventory
  • 10. • Extremely powerful Ansible module (setup) that is optionally run at the beginning of a Playbook • Gathers LOTS of information about the host that can be accessed by Playbook at runtime • Variables defined by facts can be referenced at run time by the Playbook • Useful for provisioning systems based on conditions (OS, kernel, volumes, network interfaces etc.) Get Facts
  • 11. • Ansible can either be run as an ad-hoc command or as script called a Playbook (YAML format) • Ad-hoc command is for one time command on many servers • Ad-hoc Command Usage:
 # ansible <host-pattern> -m <module> - a <arguments> -i inventory [options] Ad-hoc Command
  • 12. • Ansible ping
 # ansible all -m ping -i static • Ansible facts
 # ansible tag_Name_dev -m setup -i ec2.py --private-key =~/.ssh/private_key.pem -u ec2-user • EC2 facts
 # ansible tag_Name_dev -m ec2_facts -i ec2.py -u ec2-user — private-key=“{{ ec2_key_name }}.pem” • Install apache
 # ansible webservers -m yum -a "name=httpd state=present” -i static Ad-hoc Command Examples
  • 13. • The real power of Ansible are Playbooks • Easily readable set of tasks to perform • Include files for easy grouping of tasks • Only perform tasks on based on instance specific info (AWS instance tags, AWS instance type, OS type, etc.) • Playbook Command Usage:
 # ansible-playbook playbook.yml -i inventory [options] Playbooks
  • 14. • Comprehensive documentation on Ansible website • Example playbooks on Ansible Github repo • Ansible Galaxy - community repo of Playbooks (galaxy.ansible.com) • Ansible Tower - Commercial visual dashboard Getting Started
  • 15. • Released at beginning of 2016 • Introduced code blocks • Try-catch statements • Extended support for Windows (winrm) • Many more cloud modules Ansible 2.0
  • 16. 1. Provision instances in AWS environment 2. Apply AWS configurations (Security Groups etc.) 3. Install LAMP services 4. Copy custom configuration files, set services to on etc. Provision LAMP Stack
  • 17. • There isn’t time to do things manually if you want to remain profitable • Tasks that you thought were not easy to automate often are • Ansible does not make mistakes - people do! • Can prepare environment for Ansible with a wrapper script Tip 1: Be Lazy
  • 18. • All configuration done with SSH • All key locations are passed as a dynamically generated path • Boto credentials are set as environment variables with a wrapper script • No sensitive data ever included in playbook - customer specific data stored at a separate location Tip 2: Be Secure
  • 19. • Write playbooks that can run on many OSs • Automatically detect login user name • Use templates, dynamic inventory variables and Ansible facts • Dynamically locate customer specific variables Tip 3: Be Dynamic
  • 20. Thank you! By the way, we’re hiring:
 Cloud engineers and DevOps
 contact@cloudzone.io