You are on page 1of 21

ngble

e-po S t i p h
po
u e d
oism
mochonsm.
warano

ode

hos t
Sgh
(AC) node

Aniblu
Sewe

Cengunotten
Nonogameint
Opeh-Source
-PRide 19 aim to
to
provial
provio

and Ochutrolon Tol 4t O uoma

Depymend
Depoymend
anuaty Oh
ide
a
lasge
lange psod ucuitpuns
clalere
anille

u
sille HiS br siLla
Qnol
micha Dehaan ewelepe_d
0a
benan
in felsrua
Preje eo n aol
aaibl
Reht acaubye Debian, Cens
Debian,Ceni S
is avaslalle r RHEL
FPt Ue
Ora de linux S w w anL in

=Can ge his yo Lohmn you


HOU

clou
On-piemis 6Y in (9)A
Codirto inhastruchure I e
a f t v i b u t e s

atibutes

the Sam
epuh cnvhonet ha Some

a your applicaten
Aduatoa
HLle s e to we by eveyen
Anble e e Cowistent QnoX is ht Cwe'sht ond no
Constzant egarna
fes e OS o undluunna kardusau
OA PoUnent
i s veuy e Cuu duw to age ttey Capalti e
ael
epen ech ecwity Jebores
Pmide does not he e any pecal
odminis thotoy sElsto 'insald aue we i t

pum mechan'm
Dsoduonton t
nsdud wea
jntutace though a:ble towe
sGuP but tis A in davelepmav stoges
by anaisle
=rCanrot Qdeve ll automaHen
Umitasuppt
NewNew to e monke t o Y e
a oocumans is pwalalde

Tou ems wd in AniLle


is Inutaled
nsiLleewe-y machina w u Anible
oill be
tants anal plagpovky uoill be
na Dm
uaiDn wweh aul

Man
ampdula is a ommanol
nodule- Barvcay
Mo
enecatad on
enecatad e n a
meant to be
lommands
yoniay
Cliert-si
a
att Cowriss
Coussb
tast is a Sechon
A
Tas Completa.
t o be
protoure RL
adLaA
e
Swgle tasks onc
Ono
b g a i s i n g

Rble way a
fbole
CallA
o be de
Fles ta clent &ptem
eAche Jem Ouu
Fatnowaion gahn-lacs
t
olaVauiasles wh
evmua
u anid
e amde

dab a aloout
nuenbr y/ Ale Coudalning
leut Sauths
la ecuhen a p a y a o k

caed ony i
Tokwweh is
Handler-
nofhier is pieen wth
aiLuted a tot to
sofgiev&etkon clongl
ouput s
CalDs a hanedle bb Hu
foymat wtseh.
planlanles Conist Cook in YAML
enecated
docnbes tost to be
O u t o m a t e
by amlble
au
Jdesywhicl
ost
H o t polten
a-PAGle nventory
ec 3
Z
wtance s tn Sana e
3 eca
CYse a
anna
iilllle
e
Qud do
Qnd whb
do cwno
iuide
Anille wSewel
No
No o
paclkaye ttp: dL 1

wge latest mem


epel rlasse
-

A bm iwotal

y o m updoie -y
Pythen-eve
PythonPP
Yum
intall it python
penss awble
-
inicka annible Sw ad paste
Now $e to hesh fle
ov onvr9
vate-ip del
ho ao noola
Qna
Cweps
letelanible hests - F *
C v afe tpdbig
worne
New his
hosts fle is enly Thesb5
Coweps
Onsibl( CP l e Node i p (mivat)
Nod ie (pdvaa),
Temo ue
vi ete antbleDsible Cf
onommaided
+invendoY 2 ferc owLte kesb
+Sudo - ws = oot
eda iwed
49udo-ue

w l e Swa
ustancs
th t tlu thve e
s Ceate oe w
yousuffarsble wsu)DA
a d d u s e

his
S OSUSa U
)u Seuna
Seunam

Neu 9et podwev


yousUf
poywd

oUs yoUsoF US
SuBdh
NoU

SU YouSu
Craut4 hauwe Sudo privielg
Aont
uoosvf=> ws oosUE UseL to
Coantto ue
Rudo prhol ledge
right no ib ou
You Suf USe

Tot-i) # utsudo)
Wow 90
ida tu's l
oDE Al=AL)
OPASSwD ALL
A = (AL)
You SF

wy

inot noda abo


Nou do th t fo
UOw go eusef oneible 3uwel and ty
to

sta httpd packogac a yousof o s u

Yeunu r ] Suslo yom sws ta nttpd-


Nba etoslsh ConnecHen besueen ewe
CnoIJEaE

ho to Onnble SenvenL
31.4(9uo
LYeuay alp] 4 SSh 9a
p-pexmi'ssien Denies
clog e °ns9hed-Gnf
Wou cwe have fo do Sea
to anfble Sove
eto
Crot Oip 7 # /ete/ssh /3shd-onfa
Do Sem Chouges Sowel
has woré nrodl1 Noda alao
u veu} n anible Sower

t p) Su YoasuP
Youship] Ssh 1 31-U 2uD 2
poystwora
nte t
Nous t ast hr poow
atu tat ypu wil be inmida Nod
[eat) 44 i /etc/ssh /sshd onia
Chare (oncommut adoomment )

nammnt peumitRsotlo gin Yas


(4pamword tutarhcahon ya
Ausuuhtaton go
2
werd
mmwwe H pans

do ns all machino

gawic e 8shd Testaut


Nou e Sew Qnd CYeot e ke Ron
Yowsu
.t >,
ssh -kaygen NedaL

aLyo p
Pamwovd euuyimi| p u
etu nodh Swu Piun
we Can
Can uin Skeyse
S we
Crede public key Noda

rtRIHowhip
's- (e gsh) P o v t = Root

lp-1-ssa drso-pu)
both u,
a nodh
nod
in
ublic ke bth in
Nous
need ts Cop

s4 cd Cyouu)
143/44-2p
ansible
0@r) ¢ ssh- oPH-1
a pomuovd ( ast hm).
9A 31.u 224
CusuuA)

-id Qnsible

L J 4 SSh-Opy
pamwv laat tin
Cyouue)

Veu 8o fo owible Sewu

onllegeh ) co
ownr 1 ssh 192.34/ noole wthout poyuord,

Nou you i l l . n t n i t o
/test pate
tha maaiu in an
atl podteun e u s to ell

Mucery -list -hosb.


= ble al - - ist-hests
-antble qroupamt

o)
ist host
-
anible <demo
st
maalsne op
-sreoprom Co pleks
e0ind
Toupra 1 ) - pik
pBckes ast
last
r o n a r1 ) - matwchus
Mawehu
plek rst to fuoo
sop hams (o:1]

-opioopron pick 3,d, S 6 mesk


nHao
Aed t
pepausae b4 a Colon Coun be
Avoupe 1

e hoh dem multiple ToupS

opa e1 7 0 p nam
en demo [15): Sevops [a:to)
ec-33 Ad-hoc Cemmards Modul 4 Playhostk
TeTorag

idampoten Cemmards9mpte tinox ermmad


NO Ad-ho@
modulg - i g l e
wor)
yam(a m e module)
playbk(maye ton
yAm
4AmL3)

44-hoc Cemmand

wweh Con be Tun


tunindiuidually
irditiduallu
Command
wwh
Commands oa
-hoe
&wce onchio not a d Cenksuation
nkgulatiom
to peoTm
Commards
au not a d
ad-hoe ee -mmard) o
nee beCaue
-maogenea ard elploy nank,
C i s whage
es t /usr/bin /onitle
odhoc lommands
anaible
automate a &le taslk
Cwnmard Un tsol to
npo1 arguw

tlowelj (Ad-hoc lommands

anible (demo
Cpu r 1 ,
a r i b l e daynoloJ
-

a touch Ale z"


anible aul -a tduth Ale 4 .
tble darm -o sa t ddin )
dwible laimo-a Sudo um watall httpd -
(or) Suelo
ownble demo -ba yum iutal httd -y
t x ble damo -ba yum rmode htpd-y"
a numba q modblas Calle module
-YPudle Shps wih umota
ttecutaddvecty
on

Con be
Ga tst
hesb or roughplayhoolca'

moclules Can Tuld on an


.eYour Ubrary
Cnd TUaNA uL ho avers, daunens
mach'no

OY dosaarw Reauwrad.
woduluy o 9tora?
wun
ie
inventory fle is
at LoaHion
eee l anhible /hosh e
Qgumut
-hoolel
Anasble modlule Lemmards

M
b
Onible taveps
Ves u@ip pTesent rl
po-hHtpd
tode
= abSent (unitodU

Calest Cupddosaa

sht-kl
pkg: htpol
CJ alble deuops -b -m yom
-o

Stodeabso
Stodesalbsed

-aplghtpd

CJ8 aible dawops -b m yum


httpd Stae
tname z
Startd
Sewtce -a
anile dwops -b m
-

Cf ov
Typut"
UsL - a "rome
-

ansib le devops -b -m
na
vepudtstatea r e m O v

$ arnible deuops-b
-m Cery asrc fle4 dest-/emP
getup
r anibl e devops
m

awsibl e devops
-
m
Seup -a Glta &ipv4 a".
=

(ec-34-r Ad Plohabs Voui,4e Hondles fmps


inYaM forma
n
ehlble aL wi ten
Senalization larg
plojbook
Teadoble data laguega
- is humarn
CLed or Cer9uaten fl
tis Commonl
we you uwrlte Code
ks Ute a
l
plabeo l e t a iplakeo
Cpnsist VarS tos
handleu
and TDl
loda
moaledles
more
1s Cewnpased e n e or
-Lach playak Conlawadtion
tiles
mokule s a Collechion
in list
ike
many 8eohone like
au cliided into
Playbonles 9TOool al! wwch
tswch
t e host ogodnst
Torgat,&ckon . Detines
be execute d
towt hos to
playh mes

YAM(yt anetus Monhyp language


uth a
evu YAML Als,Start
- f wille ne\ nam
(voluu)
YousuA

ist
-Y¬ach item n Hu Gst i o Ut nkeq-valu Pe
Cewmenly Cled a diienary
with and
-> YmL lo hau b
end uiK . " ( o t maebtory)
cith
Umembers n st uhe mut bagBn
ith
ataion ) ley stautAna
- A Ust , kru lapankym
dantotlen)
-{Mango
Staus bu
18anon LM M
-\Rropes» Rosk
rple
4liechrauy a alicHenary is Reraet in a
Simp e
m
Feyyvalu
or - 4 Detel oh Cuhmu
Cuwbel:

nam Papd
08.o
Stls Ansibl
o ars
entewnen playdm fla ism
space hekaweun and valu
ag ef

.
A

S140
Vanable
wse Vaiahles wuich a dogne mourtuy
Ale
o enoble playbooks aud rolas
eveebitty
uy Can be w e fo leop trough
a sit ven
vauou inkormotion
nfovmaton
ee uo h t ona
Ualus ocem

Ylace Cukosn Shing nemplas


a tem
Sp and
,
C ith Speunc valu
9o ua
oleue task
Vauable Sechon
.-put
olethe it t we ?t fee
Now aawlble Buw ond reate m
Playbate
yoa ip) f v vars ym
my vasiable elahon

hoss deuops angt Secken.

USrtyousuf
bebenus Yey
4Conneckon sch

ars
peck
Pkgnam httP
httpd

- Name wtal httpd &we


Stateewotll
aclens um r a m *Epkarama
PTabent

C onible-playbotVers.ym
Haudlers econ
handles is exackly ha Same a a task,bud itwlt
YA anethu -task.
on
when lled by
osle
Dustble
Ge e
euul
laar
r tasts in
tasty an
an

lancdles ou us ontosns
Contosn
u onl Tun t t toulc
bu 1t
elayhoole, ino'cates tnt
drechve a n albo
a rotta
change Somehina
ordt orect
Corecsy
RY Rv laybak is ovmatt
Check t e e h t t hec
c h e c

playbot-rant

bleplagbk
-darss

aideSowu
Yeua/ hourollert. ym
-tPanodleu plaloook

-hosts devops T a n g e t
S e c h o n

US YooluA

beCom
ConnecH on 9sh

nama nstall 77Pd &ewer


noma httpe Stateeinstasuleok
ocHen Hum
nofib1 Tutart ktyp
handlers
ond lers:
-name: utart httpo
State-Yetavte
achen: Suwice nomu=htfpe

Kew exeCute this pafooo

. J 6onible -poybak kandks-ym

kLsops tim
his yeu uoad to Ypet tosk muliple
a

this is Caledleops anaAe


h otmpu ogTomnng ,

rhble dops Comnen fynille lops incude chorgng


wh
adJoY drecorie
Dwnashp en Seyal fu e cwim the USeLMmedlu
M Meelule CYeahrg mulkiple
4sea and Tpeskig a pollng 3tp
Ce ulple
cetodn Result s Rachecd.
Ont

Now goo ansilble Suwon

- #my onps plaupco


hes ts:. okewops
USe: Yeusu
Taget Secion.
belema y
Cenneehen Ssh
as ode a Ust
st o wewM
ina
USen name = Ltem? stde=prennt
with-item
Shopid
Zeesha
kighov
Amaly

Saman

CI aible -playbook loops.ym


insid Nodii
T uer '
TsCA/etc/pamuwd: t . o po
Koles nwble
(ec+3-loudhon
Vauls and

CondlsHons
lohdihonr Scenamos,
we pat
we
lawe d u a t
baneu
whenev
arcoselkg to tea eenado
(wlan)
Statemat (omnaual
pautelar
to Sp
a

done tinu you cwant


t a pokcwlan nool

# Coudstten playboo
hosh: oweps
USn: yusup angt Acho
Cennechon 3h
apacle en deoran
name: itall
-Y imtatl apache
Command apt-gut
wuny ansble_0s_faily =Debian
apaehe edhat
nome: tall
en

Commod Ypm-y instl httpd u


o n anibleos_fonlyi= =l"RedHat

Vault Such
teapin
allpus Sentive dhta as pouwovols
Aibl
r ke n noruptals, abtun tuana plsntextin
your Playaots
Craakng a neuw
encrytad playp
auible-Uault Create VaulltyM

e d s t t e encrytoplayba

vault elsE vaultyml DESas6att


auible- enryho

ta pouoorol
T o chonge
a i d e - voult se ke uaiulyn
To encryp an e
ishin Plaoao

canible- vault encrup taatym

T o De crypt an encryplad lobok


anfble-aut dbcpt targatyml/
Roley

weCon cuewofechniau) oY
ewina Set tasks:-înclagas

Beui
and o l e
Rofes(dir)
AOn m
-Reles ou goodo OYganain2 myroleN

Tget
ond eh Cafsuloahng lat
a Rol
tasks MA

those tast| Myrole

neeedto accomplish Vaiasle

usible Rele Vor SS


mea

nb deckor
playloso k9
a
w e Can OVsanise

&truchure Co00 Tole. to a plofpeobs


neonality

anod
more
1 a Sige
Sle gile
Srale Fl
ble
-ndding more

to mointen in a

will mae t eln icult


dota oecole/applcbon
tue
DeauAY }E Sthve Yon Yon pTt 9o
to poTt yo
wo
u on
nt %
eg- you ph
Dejanlst
Dejau
Vowahles in i s
neels to deine
Or 80Po n vouuable

to
edto be tranjeTved
les gt lortosra fe
ta TemoteyM (Sahe ile)
Can angade
Hond lers rla au tyiasers or tasks we

all ta hanelers urafn playbopk


Stolb un
eStblish
Coutain
net : w dveckory nanu, Suppete
Audhey
oles dependoncias
plaspTm, Dopendlencdo an
isnormly
Contodn aull e tasks tuat
Toty nstallr pocka
in tu eq
playbok
and Coples flu etec
Vaulabley b Hs ole Coun be &pecie i
dvars flu
Conlgulaion
and usd agpur
drechory yanablas..
eleseult &ore
peh Vars and 2r

habweter
-yowsu le)B mtalbr P playhenk/Yoles/wessuef tas
C J tree
C33 cA playbaok
J tree
, C' touch Tolul webtawu /tasts/ maony)
C touoh matr qm 9

C v rolowebswa bastamasn-ymi
naidle man.ym
3

You might also like