Infraestructura como código

Festival Politraining Industria 4.0

Infraestructura como código

En este nuevo artículo me gustaría explicar que es infraestructura
como código (IAC), pero primero definamos a que nos referimos cuando
hablamos sobre infraestructura.
Cuando hablamos de infraestructura nos referimos en este caso, a un
servidor(vps) , dominios, redes privadas. etc.

Definición

El concepto de infraestructura como código no es más que la forma de
automatización de nuestra infraestructura a través de código .

Puede que tu seas un freelance o trabajes en una compañía, en la que
constantemente se hace deploy de nuevas aplicaciones.
Imagina tener que estar creando un servidor(vps), agregando las llaves
ssh, creando un record A, load balancers, continuar con la instalación y
configuración de nginx ,mysql docker, php, etc. Todo esto cada vez que
tengas que hacer deploy de una nueva aplicación.
Este es un proceso en el que muchas veces se le dedica tiempo
innecesario.

Es por ello que muchas veces, es mejor encontrar o crear una solución para la automatización en este tipo de procesos.

Para poder trabajar o usar infraestructura como código, lo único que
tenemos que hacer es bien, crear nuestro propio script, o bien usar
alguna herramienta de un tercero.

Usualmente cuando trabajamos con infraestructura como código,
independiente de la herramienta que usamos, siempre trabajamos con algún
lenguaje para la descripción de la configuración, pudiendo ser json,
yaml o algún nuevo lenguaje propio del software (domain-specific
language ). dentro del archivo de configuración, es donde definiremos
todo los componentes necesarios para crear nuestra infraestructura,
variando de sintaxis entre los diferentes softwares que podemos usar.

Cabe mencionar que, usualmente este tipo de software nos permite,
configurar a nuestra infraestructura, de una manera muy detallada,
dependiendo del tipo de proveedor que elijamos , por ejemplo, poder
configurar redes privadas, sistema operativo, podemos agregar dominios,
subdominios , agregar nuestra claves ssh, elegir el datacenter etc. Algo
interesante es que, podemos agregar y ejecutar scripts dentro del vps
durante la construcción, esto para poder configurar dentro todo el
software.

Aunque de igual forma, tenemos otro concepto llamado configuración
como código (CaC)
Qué es exactamente el mismo concepto, pero este está orientado a la
configuración del software dentro de la infraestructura(vps), por
ejemplo la instalación y configuración de nginx, docker, ruby etc. Sin
embargo muchas veces los mismos proveedores (IaC) tienen la misma
funcionalidad o su funcionalidad es intercambiable.

Ventajas y desventajas.

Dentro de las ventajas como hemos mencionado es el de elaborar una
plantilla que podemos re-utilizar múltiples veces, eliminando la
necesidad de realizar configuraciones manuales. Esta sería, la principal
y más importante característica de este tipo de software.
Ya que con ello podemos hacer la replicación de la misma configuración,
para diferentes entornos, para testing, QA, producción, desarrollo, etc.

Otra ventaja que podemos encontrar es que usualmente este tipo de
software es del tipo agnóstico lo que quiere decir que no importa, el
proveedor en donde estés configurando nuestra infraestructura, pudiendo
ser digital ocean, amazon web services, azure, e inclusive virtualbox.

Una desventaja que podemos encontrar es quizá el tiempo que le
dedicamos en configurar nuestro archivo de configuración, así mismo, el
tener que modificar el archivo si es que agregamos una nueva tecnología o
configuración a nuestra infraestructura.

Lista de software para IaC y CaC

Debajo vemos una lista con varios de los proveedores de infraestructura y configuración como código más sobresalientes.
Cada uno de ellos comparten cierta similitud, en cuanto a configuración.

  • Terraform
  • Chef
  • Puppet
  • Ansible
  • SaltStack

Conclusión

La automatización es sin duda una de las mejores cosas que podemos
hacer para ahorrar tiempo y muchas veces recursos.
El uso de IaC, dentro de una empresa o de manera independiente trae
muchas ventajas a largo plazo. Este concepto de IaC no es para nada
nuevo, es un concepto de muchos años. De hecho muchos autores. hacen
referencia a que este concepto fue la base de la cual ha surgido toda
esta tendencia del devops.
Espero que este pequeño artículo te haya servido, o te haya incentivado a
investigar más sobre el tema, y tal vez a aprender una nueva
tecnología.

Comments: 21,281

  1. Everything is very open with a really clear explanation of the issues.
    It was really informative. Your site is very helpful.
    Thanks for sharing!

  2. Heya! I’m at work surfing around your blog from my new iphone 3gs!

    Just wanted to say I love reading through your blog and look forward to all your
    posts! Carry on the superb work!

  3. Комедия детства фильм один дома — легендарная комедия для всей семьи. Без ограничений, в отличном качестве, на любом устройстве. Погрузитесь в атмосферу праздника вместе с Кевином!

  4. Комедия детства один дома — легендарная комедия для всей семьи. Без ограничений, в отличном качестве, на любом устройстве. Погрузитесь в атмосферу праздника вместе с Кевином!

  5. Everyone loves what you guys tend to be up too.
    This kind of clever work and coverage! Keep up the fantastic works guys I’ve included you guys to blogroll.

  6. mac repair dice:

    I don’t even know how I ended up here, but I thought this post was great.
    I don’t know who you are but definitely you are going to
    a famous blogger if you are not already 😉 Cheers!

  7. Alonso AI dice:

    Howdy, i read your blog occasionally and i own a similar one and i was
    just wondering if you get a lot of spam feedback? If so how do you stop it, any plugin or anything you can advise?
    I get so much lately it’s driving me mad so any support is very much appreciated.

  8. Hi there, yes this post is really fastidious and I have
    learned lot of things from it about blogging. thanks.

  9. Продвижение сайта https://team-black-top.ru в ТОП Яндекса и Google. Комплексное SEO, аудит, оптимизация, контент, внешние ссылки. Рост трафика и продаж уже через 2–3 месяца.

  10. I blog often and I really appreciate your content.
    Your article has truly peaked my interest.
    I am going to take a note of your blog and keep checking for new details
    about once per week. I subscribed to your Feed too.

  11. togel online dice:

    Everyone loves what you guys are up too. This sort of clever work and reporting!
    Keep up the superb works guys I’ve incorporated you
    guys to blogroll.

  12. Hello there! This is my first comment here so I just wanted
    to give a quick shout out and tell you I truly enjoy
    reading through your posts. Can you suggest any other blogs/websites/forums that cover the same topics?
    Thanks for your time!

  13. Jermaine dice:

    I’m not that much of a online reader to be honest but your
    sites really nice, keep it up! I’ll go ahead and bookmark your site to come back later.
    Cheers

  14. sv88 dice:

    It’s hard to find knowledgeable people for this subject, but you sound like you know what you’re talking about! Thanks

  15. I love your blog.. very nice colors & theme. Did you create this website yourself or did you hire someone to do it for you?
    Plz answer back as I’m looking to create my own blog and would like
    to find out where u got this from. appreciate it

  16. keluaran sdy dice:

    Wow, this piece of writing is fastidious, my sister is analyzing these things, thus I am going to convey her.

  17. m88 dice:

    Good post however , I was wondering if you could write a litte more on this subject?

    I’d be very grateful if you could elaborate a little bit further.
    Thank you!

  18. Nice answer back in return of this difficulty with genuine arguments and telling everything regarding
    that.

  19. Pretty great post. I just stumbled upon your weblog and wanted
    to say that I have really enjoyed browsing your blog posts.
    In any case I’ll be subscribing for your feed and I’m hoping you write
    once more soon!

  20. setor 123 dice:

    Hey! Do you know if they make any plugins to help with Search Engine Optimization? I’m trying to get my blog to rank for some targeted keywords but I’m not
    seeing very good success. If you know of any please
    share. Kudos!

  21. Incredible points. Outstanding arguments. Keep up the great spirit.

  22. ramatogel dice:

    Wonderful blog! I found it while surfing around on Yahoo News.
    Do you have any tips on how to get listed in Yahoo News?
    I’ve been trying for a while but I never seem to get there!
    Appreciate it

  23. Hi, i read your blog from time to time and i own a similar
    one and i was just wondering if you get a lot of
    spam responses? If so how do you reduce it, any
    plugin or anything you can recommend? I get so much lately it’s driving me insane so any help is very much
    appreciated.

  24. 破解软件 dice:

    It’s amazing to visit this site and reading
    the views of all colleagues about this paragraph, while I am also
    zealous of getting knowledge.

  25. Cabinet IQ
    15030 N Tatum Blvd #150, Phoenix,
    AZ 85032, United Ѕtates
    (480) 424-4866
    Refreshed (https://www.symbaloo.com/)

  26. olxtoto akun dice:

    This is a topic that’s near to my heart… Cheers!
    Where are your contact details though?

  27. This post will assist the internet visitors for building up new weblog or even a blog
    from start to end.

  28. fcb8 dice:

    It’s hard to come by knowledgeable people in this particular topic, however, you sound like you know what you’re talking about! Thanks

  29. toto slot dice:

    I blog often and I genuinely appreciate your content.
    Your article has truly peaked my interest. I will bookmark your blog
    and keep checking for new details about once a week.
    I opted in for your RSS feed as well.

Responder a kikototo Cancelar respuesta