Giter Club home page Giter Club logo

ansible-rsktech-cloudthat's Introduction

All these examples are tested on EC Instance created using the AMI for Amazon Linux.

You can install ansible on any of the EC2 Instance created with Amazon Linux AMI using below command

sudo amazon-linux-extras install ansible2 

Verify ansible version using below.

ansible –version

You should see output similar to below

alt text

Below are some of the basic commands to start with

Test SSH connectivity with the local machine

ansible localhost -m ping	

create a new file 'inputfile.txt' in the user home directory on local machine

ansible localhost -m shell -a "touch inputfile.txt"	

list contents of home directory on the local machine

ansible localhost -m shell -a "ls -ltr /home/ec2-user"	

Install wget on local machine using the shell module

ansible localhost -m shell -a "yum install wget" -b	

Install wget on local machine using yum module (as root user)

ansible localhost -m yum -a "name=wget state=present" -b	

Uninstall wget from local machine, using yum module and elevate privileges to root

ansible localhost -m yum -a "name=wget state=absent" -b	

ansible-rsktech-cloudthat's People

Contributors

mandar-dindorkar avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.