Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Automatización de sistemas con Ansible - OpenSo...
Search
zisk0
May 07, 2016
Technology
1
34
Automatización de sistemas con Ansible - OpenSouthCode 16
Automatización de sistemas con Ansible - OpenSouthCode 16
zisk0
May 07, 2016
Tweet
Share
Other Decks in Technology
See All in Technology
BidiAgent と Nova 2 Sonic から考える音声 AI について
yama3133
2
140
「リリースファースト」の実感を届けるには 〜停滞するチームに変化を起こすアプローチ〜 #RSGT2026
kintotechdev
0
510
AI時代のアジャイルチームを目指して ー スクラムというコンフォートゾーンからの脱却 ー / Toward Agile Teams in the Age of AI
takaking22
9
3.5k
形式手法特論:コンパイラの「正しさ」は証明できるか? #burikaigi / BuriKaigi 2026
ytaka23
15
3.8k
AI との良い付き合い方を僕らは誰も知らない (WSS 2026 静岡版)
asei
1
220
『君の名は』と聞く君の名は。 / Your name, you who asks for mine.
nttcom
1
140
Introduction to Bill One Development Engineer
sansan33
PRO
0
340
松尾研LLM講座2025 応用編Day3「軽量化」 講義資料
aratako
15
4.9k
あの夜、私たちは「人間」に戻った。 ── 災害ユートピア、贈与、そしてアジャイルの再構築 / 20260108 Hiromitsu Akiba
shift_evolve
PRO
0
370
小さく、早く、可能性を多産する。生成AIプロジェクト / prAIrie-dog
visional_engineering_and_design
0
320
All About Sansan – for New Global Engineers
sansan33
PRO
1
1.3k
Master Dataグループ紹介資料
sansan33
PRO
1
4.2k
Featured
See All Featured
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
1
100
Practical Orchestrator
shlominoach
190
11k
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
1
270
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.1k
Bootstrapping a Software Product
garrettdimon
PRO
307
120k
Keith and Marios Guide to Fast Websites
keithpitt
413
23k
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
210
The Curse of the Amulet
leimatthew05
0
6.7k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Building the Perfect Custom Keyboard
takai
2
670
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
0
270
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.3k
Transcript
Automatización de sistemas con
Whois Francisco López Sysadmin
Sysadmin: the hard way
The hard way ▪ Máquinas con configuración similar ▪ Servidores
“artesanos”
Simple IT Automation
Ansible ▪ Aprovisionamiento ▪ Gestión de la configuración ▪ Orquestación
▪ Despliegue de aplicaciones
Caracteristicas ▪ Simple pero potente Configuración en YAML. Plantillas en
jinja2. ▪ Sin agentes Usa SSH. ▪ Segura ...eehm, bueno, todo lo seguro que sea SSH.
Caracteristicas ▪ Muy bien documentada ▪ Respaldada por Red Hat
¡Es software libre! ▪ Core licenciado como GPLv3 ▪ Modulos
libres ▪ Roles libres
Ansible 101 Conceptos básicos
Inventory 192.168.1.10 opensouthcode.org [webservers] web1.osc.org web2.osc.org [databases:children] databases-masters databases-slaves [databases-masters]
master[1:3].osc.org [databases-slaves] slaves[1:3].osc.org Listado de máquinas
- name: Instalar vim apt: pkg=vim state=present update_cache=yes Task Acción
a realizar Compuesta de módulo y parámetros apt update && apt install vim
Módulos Amazon EC2 Amazon ECS Amazon S3 Command MongoDB Redis
MySQL Postgres IIS Windows Nagios Zabbix RabbitMQ Azure Digital Ocean Docker Google Cloud VMWare Rackspace Linux Apache2 Django JBOSS Jira Git Github Subversion F5 Cisco HAProxy
Play Inventario + tareas - name: Play simple de ejemplo
hosts: webservers tasks: - name: Instalar vim apt: pkg=vim state=present update_cache=yes - name: Instalar tcpdump apt: pkg=tcpdump state=present
Playbook Sucesión de plays Base de ejecución de Ansible
Config management
Variables app_path: “/home/app” monitoring: server-name: nagios server: 11.22.33.44 Se pueden
definir “en cualquier sitio”
inventario host_vars group_vars main.yml web.osc.org.yml --- app_path: “/home/app” servername: “web.osc.org”
monitoring: server-name: “nagios” server: 11.22.33.44
Variables - name: Clonar repositorio git:repo="
[email protected]
:app.git" clone=yes dest={{ app_path }}
Se referencian usando jinja2
Templates Aplicar variables a ficheros de configuración <VirtualHost _default_:{{ http_port
}}> ServerName {{ servername }} ...
Templates Aplicar variables a ficheros de configuración - name: Subir
config apache template: src=00-app.conf.j2 dest=/path/00-app.conf owner=root group=root mode=0644
inventario host_vars group_vars main.yml templates 00-app.conf.j2
Inclusión y roles
Inclusión En un playbook se pueden incluir otros ficheros con
tasks --- - hosts: webservers tasks: - include: dependencies.yml - include: deployment.yml - include: apache.yml
Roles Encapsulación de configuraciones --- - hosts: webservers roles: -
base - django - apache2
inventario host_vars group_vars main.yml templates roles
apache2 files meta roles handlers tasks vars templates
¿Resultados?
None
¡Gracias! ¿Preguntas? @zisk0
[email protected]