<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Augusto Valdivia</title>
    <description>The latest articles on DEV Community by Augusto Valdivia (@valaug).</description>
    <link>https://dev.to/valaug</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F637781%2F1cf3dd02-fe7e-4dd8-9b30-93f0b09fdb4c.jpg</url>
      <title>DEV Community: Augusto Valdivia</title>
      <link>https://dev.to/valaug</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/valaug"/>
    <language>en</language>
    <item>
      <title>El error de seguridad más común es “Dale Admin y Ya” Cómo solucionarlo con Terraform</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Mon, 22 Dec 2025 21:28:18 +0000</pubDate>
      <link>https://dev.to/aws-espanol/el-error-de-seguridad-mas-comun-es-dale-admin-y-ya-o82</link>
      <guid>https://dev.to/aws-espanol/el-error-de-seguridad-mas-comun-es-dale-admin-y-ya-o82</guid>
      <description>&lt;p&gt;Cuando estamos bajo presión, casi siempre gana la solución más rápida. Algo falla, alguien necesita acceso, hay una entrega cerca. Entonces hacemos lo típico: damos permisos amplios “por ahora”.&lt;/p&gt;

&lt;p&gt;El problema es que lo temporal suele quedarse para siempre.&lt;/p&gt;

&lt;p&gt;Menor privilegio no es paranoia. Es intención. Damos solo lo necesario para que los errores tengan un impacto pequeño y la seguridad sea más predecible.&lt;/p&gt;

&lt;h2&gt;
  
  
  Qué significa menor privilegio de verdad
&lt;/h2&gt;

&lt;p&gt;Menor privilegio significa:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Solo las acciones necesarias&lt;/li&gt;
&lt;li&gt;Solo los recursos necesarios&lt;/li&gt;
&lt;li&gt;Solo cuando se necesita&lt;/li&gt;
&lt;li&gt;Solo para la identidad correcta&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Una buena política responde:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Qué necesita hacer este sistema&lt;/li&gt;
&lt;li&gt;En qué recursos lo hará&lt;/li&gt;
&lt;li&gt;Qué cosas nunca debería poder hacer&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;IAM no es solo seguridad. IAM también es estabilidad. Un rol con demasiado poder puede romper más cosas más rápido.&lt;/p&gt;

&lt;h2&gt;
  
  
  Por Qué Importa a Gran Escala
&lt;/h2&gt;

&lt;p&gt;En entornos pequeños, los permisos amplios tal vez no exploten de inmediato. En entornos grandes, tarde o temprano sí.&lt;/p&gt;

&lt;p&gt;Menor privilegio te protege de:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Impacto masivo si una credencial se compromete&lt;/li&gt;
&lt;li&gt;Borrados accidentales en producción&lt;/li&gt;
&lt;li&gt;Roles antiguos que nadie recuerda&lt;/li&gt;
&lt;li&gt;Auditorías difíciles de explicar&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Además, ayuda a depurar. Si algo falla, sabemos que los límites de acceso son reales.&lt;/p&gt;

&lt;h2&gt;
  
  
  Dónde Fallamos Normalmente
&lt;/h2&gt;

&lt;p&gt;Los patrones más comunes son:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Wildcards como &lt;code&gt;*:*&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Políticas copiadas sin limpieza&lt;/li&gt;
&lt;li&gt;Un rol para todo&lt;/li&gt;
&lt;li&gt;Permisos temporales que nunca se quitan&lt;/li&gt;
&lt;li&gt;No separar permisos de despliegue y ejecución&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Esto les pasa a equipos buenos también. La solución es un patrón claro.&lt;/p&gt;

&lt;h2&gt;
  
  
  Ejemplos: Mala Política vs Buena Política
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Ejemplo 1: Acceso a S3
&lt;/h3&gt;

&lt;h4&gt;
  
  
  ❌ Mala política (demasiado amplia)
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"Version"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"2012-10-17"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"Statement"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Effect"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Allow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Action"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"s3:*"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Resource"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"*"&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  ✅ Buena política (limitada y práctica)
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"Version"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"2012-10-17"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"Statement"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Sid"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"ListBucketInPrefix"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Effect"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Allow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Action"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"s3:ListBucket"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Resource"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"arn:aws:s3:::my-app-data"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Condition"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="nl"&gt;"StringLike"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
          &lt;/span&gt;&lt;span class="nl"&gt;"s3:prefix"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"public/*"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Sid"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"ReadObjectsInPrefix"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Effect"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Allow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Action"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"s3:GetObject"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Resource"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"arn:aws:s3:::my-app-data/public/*"&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Un Sistema Simple para Diseñar IAM Bien
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Separar roles&lt;/li&gt;
&lt;li&gt;Empezar mínimo y crecer cuando sea necesario&lt;/li&gt;
&lt;li&gt;Usar guardrails como SCPs y boundaries&lt;/li&gt;
&lt;li&gt;Revisar y limpiar permisos regularmente&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  🧪 Mini Proyecto: Rol de Menor Privilegio para Lambda + S3 usando Terraform.
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Objetivo
&lt;/h3&gt;

&lt;p&gt;Crear:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Un bucket S3&lt;/li&gt;
&lt;li&gt;Un rol de ejecución de Lambda&lt;/li&gt;
&lt;li&gt;Una política de menor privilegio&lt;/li&gt;
&lt;li&gt;Adjuntar la política al rol&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;La Lambda podrá:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Leer solo de &lt;code&gt;public/&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Escribir solo en &lt;code&gt;results/&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Escribir logs en CloudWatch&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  ¿Quieres verlo todo en acción?
&lt;/h2&gt;

&lt;p&gt;Completa este despliegue arquitectónico utilizando este repositorio de GitHub - &lt;a href="https://github.com/ValAug/IAM_least_privilege" rel="noopener noreferrer"&gt;Demostración de IAM Least Privilege&lt;/a&gt;. Siéntete libre de explorar otros proyectos en los que he trabajado. &lt;/p&gt;

&lt;p&gt;Si este artículo te ayudó, aquí está lo que puedes hacer después:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Sígueme&lt;/strong&gt; en &lt;a href="https://x.com/TerraSpacio" rel="noopener noreferrer"&gt;X&lt;/a&gt; y &lt;a href="https://www.youtube.com/@TerraSpacio" rel="noopener noreferrer"&gt;YouTube&lt;/a&gt; para más contenido de AWS, DevOps y Terraform,para principiantes o expertos. También comparto miniproyectos en nuestro newsletter ☕ Cloud Café &lt;a href="https://www.linkedin.com/build-relation/newsletter-follow?entityUrn=7373717160319299584" rel="noopener noreferrer"&gt;Subscríbete en LinkedIn&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>terraform</category>
      <category>awsseguridad</category>
      <category>awsdevops</category>
      <category>awsespañol</category>
    </item>
    <item>
      <title>IAM Least Privilege: What Everyone Gets Wrong (and How to Fix It with Terraform)</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Wed, 17 Dec 2025 15:29:39 +0000</pubDate>
      <link>https://dev.to/aws-builders/iam-least-privilege-what-everyone-gets-wrong-and-how-to-fix-it-with-terraform-2k5j</link>
      <guid>https://dev.to/aws-builders/iam-least-privilege-what-everyone-gets-wrong-and-how-to-fix-it-with-terraform-2k5j</guid>
      <description>&lt;p&gt;When we’re under pressure, the fastest solution often wins. Someone needs access, something is failing, and a deadline is approaching. So we do the classic move: grant wide permissions “temporarily.”&lt;/p&gt;

&lt;p&gt;The problem is that temporary permissions have a habit of becoming permanent.&lt;/p&gt;

&lt;p&gt;Least privilege isn’t about being paranoid. It’s about being intentional. We grant only what’s needed, so mistakes stay small, and security remains predictable.&lt;/p&gt;

&lt;h2&gt;
  
  
  What does least privilege actually mean?
&lt;/h2&gt;

&lt;p&gt;Least privilege means:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Only the actions needed (not everything)&lt;/li&gt;
&lt;li&gt;Only the resources needed (not “any resource”)&lt;/li&gt;
&lt;li&gt;Only when needed (not forever)&lt;/li&gt;
&lt;li&gt;Only for the right identity (role, user, or service)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;With these points in mind, I always ask myself the following questions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;What does this workload need to do?&lt;/li&gt;
&lt;li&gt;Where does it need to do it?&lt;/li&gt;
&lt;li&gt;What should &lt;strong&gt;&lt;em&gt;never&lt;/em&gt;&lt;/strong&gt; be allowed?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This mindset matters because IAM is not just about security; it’s also about reliability.&lt;br&gt;
A role with too much power can break more things, faster.&lt;/p&gt;
&lt;h2&gt;
  
  
  Why Least Privilege Matters at Scale
&lt;/h2&gt;

&lt;p&gt;In small environments, wide permissions might not cause immediate problems.&lt;br&gt;
At scale, they usually do.&lt;/p&gt;
&lt;h4&gt;
  
  
  Here’s what least privilege protects you from:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;A larger blast radius:&lt;/strong&gt; one compromised key can impact everything&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Accidental deletions:&lt;/strong&gt; someone runs the wrong command in production&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Shadow access:&lt;/strong&gt; old roles retain permissions nobody remembers granting&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Audit headaches:&lt;/strong&gt; difficult questions like “Why does this role have this access?”&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;When permissions are tight, debugging becomes easier as well.&lt;br&gt;
If something fails, we know the access boundary is real and meaningful.&lt;/p&gt;
&lt;h2&gt;
  
  
  Where Teams Usually Go Wrong
&lt;/h2&gt;

&lt;p&gt;These are the most common patterns we see in real AWS environments:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Wildcards like:*&lt;/li&gt;
&lt;li&gt;Policies copied from the internet and never cleaned up&lt;/li&gt;
&lt;li&gt;A single role reused across multiple systems&lt;/li&gt;
&lt;li&gt;“Temporary” permissions that quietly become permanent&lt;/li&gt;
&lt;li&gt;No separation between deployment permissions and runtime permissions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This happens to good teams as well. It usually comes from moving fast.&lt;br&gt;
The fix isn’t blame; the fix is adopting the right patterns.&lt;/p&gt;
&lt;h2&gt;
  
  
  Bad Policy vs Good Policy Examples
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Example 1: S3 access&lt;/em&gt;&lt;/strong&gt;&lt;br&gt;
❌ Bad policy (too broad)&lt;/p&gt;

&lt;p&gt;This allows any S3 action on any bucket.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Effect": "Allow",
      "Action": "s3:*",
      "Resource": "*"
    }
  ]
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Why This Is Risky
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Can delete any bucket&lt;/li&gt;
&lt;li&gt;Can read data that should be private&lt;/li&gt;
&lt;li&gt;No limits on specific paths or environments&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;✅ Good Policy (Tight and Practical)&lt;/p&gt;

&lt;p&gt;This policy grants read-only access to a single bucket, limited to a specific prefix.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Sid": "ListBucketInPrefix",
      "Effect": "Allow",
      "Action": ["s3:ListBucket"],
      "Resource": "arn:aws:s3:::my-app-data",
      "Condition": {
        "StringLike": {
          "s3:prefix": ["public/*"]
        }
      }
    },
    {
      "Sid": "ReadObjectsInPrefix",
      "Effect": "Allow",
      "Action": ["s3:GetObject"],
      "Resource": "arn:aws:s3:::my-app-data/public/*"
    }
  ]
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Why This Is Better
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Limited to a single bucket&lt;/li&gt;
&lt;li&gt;Limited to a specific path&lt;/li&gt;
&lt;li&gt;No delete permissions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Example 2: Lambda Logging&lt;/em&gt;&lt;/strong&gt;&lt;br&gt;
❌ Bad Policy&lt;/p&gt;

&lt;p&gt;This policy allows writing logs anywhere, which is unnecessary and risky.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;{
  "Effect": "Allow",
  "Action": "logs:*",
  "Resource": "*"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;✅ Good Policy&lt;/p&gt;

&lt;p&gt;This policy allows only log stream creation and log writing for one specific log group.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;{
  "Effect": "Allow",
  "Action": [
    "logs:CreateLogStream",
    "logs:PutLogEvents"
  ],
  "Resource": "arn:aws:logs:us-east-1:123456789012:log-group:/aws/lambda/my-function:*"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  A Simple System to Design IAM the Right Way
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Here’s a pattern that works in real projects:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Separate roles&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Use different roles for different responsibilities:&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;One for deployment&lt;/li&gt;
&lt;li&gt;One for runtime&lt;/li&gt;
&lt;li&gt;One for monitoring&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Start narrow, expand only when needed&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;When an action fails, add only the minimum permission required to fix it.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Use guardrails&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Apply SCPs and permission boundaries to enforce “&lt;em&gt;this must never happen&lt;/em&gt;” rules.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Review regularly&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;If a permission hasn’t been used in months, remove it.&lt;/li&gt;
&lt;li&gt;Least privilege is not a one-time setup.&lt;/li&gt;
&lt;li&gt;It’s a maintenance habit.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🧪 Mini Project: Least-Privilege IAM Role for Lambda + S3
&lt;/h3&gt;

&lt;p&gt;(Terraform &lt;strong&gt;Coming-Soon&lt;/strong&gt;)&lt;/p&gt;

&lt;h4&gt;
  
  
  Goal
&lt;/h4&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;We will create:&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;One S3 bucket&lt;/li&gt;
&lt;li&gt;One Lambda execution role&lt;/li&gt;
&lt;li&gt;One least-privilege IAM policy&lt;/li&gt;
&lt;li&gt;Attach the policy to the role&lt;/li&gt;
&lt;li&gt;The Lambda will be able to:&lt;/li&gt;
&lt;li&gt;Read only from s3://bucket/public/*&lt;/li&gt;
&lt;li&gt;Write only to s3://bucket/results/*&lt;/li&gt;
&lt;li&gt;Write logs to CloudWatch&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Want to see it all in action?
&lt;/h2&gt;

&lt;p&gt;Complete this architectural deployment using this GitHub repository - &lt;a href="https://github.com/ValAug/IAM_least_privilege" rel="noopener noreferrer"&gt;IAM Least Privilege Demo&lt;/a&gt;. Feel free to explore other projects I've worked on.&lt;/p&gt;

&lt;p&gt;If this article helped you, here’s what you can do next:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Follow me on&lt;/em&gt;&lt;/strong&gt; &lt;a href="https://x.com/TerraSpacio" rel="noopener noreferrer"&gt;X&lt;/a&gt; and &lt;a href="https://www.youtube.com/@TerraSpacio" rel="noopener noreferrer"&gt;YouTube&lt;/a&gt; for more AWS, DevOps, and Terraform content that’s beginner-friendly.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Leave a comment&lt;/em&gt;&lt;/strong&gt; with your thoughts, your own AWS journey, or questions you’d like me to cover next.&lt;/p&gt;

</description>
      <category>terraform</category>
      <category>awssecurity</category>
      <category>aws</category>
      <category>devops</category>
    </item>
    <item>
      <title>AWS Summit Toronto 2025: De la Supervisión Humana a la IA Agéntica</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Fri, 12 Sep 2025 17:59:56 +0000</pubDate>
      <link>https://dev.to/aws-espanol/aws-summit-toronto-2025-reflexiones-de-dos-dias-inspiradores-3m9n</link>
      <guid>https://dev.to/aws-espanol/aws-summit-toronto-2025-reflexiones-de-dos-dias-inspiradores-3m9n</guid>
      <description>&lt;p&gt;La semana pasada tuve la oportunidad de asistir al &lt;strong&gt;AWS Summit Toronto 2025&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0j2udrsrj3voyq31c1t2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0j2udrsrj3voyq31c1t2.png" alt="Toronto" width="800" height="800"&gt;&lt;/a&gt;&lt;br&gt;
Este año el evento se dividió en dos partes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Día 1 – Partner Summit&lt;/strong&gt;, dedicado a los socios de AWS.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Día 2 – Open Summit&lt;/strong&gt;, abierto a toda la comunidad de AWS.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Fueron dos días llenos de aprendizaje, inspiración y anuncios sobre el futuro. Pero más que nada, fue una oportunidad para conectar — con colegas, líderes y con toda la comunidad de AWS.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Día 1 – Lo más Destacado del Partner Summit&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;El primer día estuvo enfocado en los socios y en un repaso profundo del portafolio más reciente de AWS. Algunos de los temas tratados fueron:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;La Anatomía de la Velocidad&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Soluciones Industriales y Seguridad&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Generative AI y Migración/Modernización&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Evolución del AWS Marketplace&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;El mayor foco estuvo en la &lt;strong&gt;IA Agéntica (Agentic AI)&lt;/strong&gt;. AWS presentó un portafolio que conecta herramientas como &lt;strong&gt;Amazon Q, AWS Transform, Amazon Connect, modelos Nova y Bedrock&lt;/strong&gt;, todo unificado con nuevos SDKs y servicios para construir agentes inteligentes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Temas clave:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Flexibilidad con OSS e integraciones de partners.&lt;/li&gt;
&lt;li&gt;Guardrails de personalización para construir de manera responsable.&lt;/li&gt;
&lt;li&gt;Soluciones verticales para industrias como SAP, Oracle y mainframes.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AWS Transform&lt;/strong&gt; como el primer servicio de IA agéntica para migración y modernización, mostrando resultados impresionantes como evaluaciones de documentación más rápidas y reducción de costos de licencias.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Día 2 – Temas del Open Summit&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;El segundo día amplió la visión hacia el futuro de la nube. La evolución fue clara:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;De &lt;strong&gt;asistentes de IA generativa&lt;/strong&gt; → a &lt;strong&gt;agentes de IA generativa&lt;/strong&gt; → hasta &lt;strong&gt;sistemas de IA agéntica&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Menos supervisión humana, más automatización y sistemas multiagente capaces de razonar como humanos.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Este cambio hacia la &lt;strong&gt;IA agéntica&lt;/strong&gt; marca el próximo capítulo en la nube — donde las cargas de trabajo no solo corren en AWS, sino que también toman decisiones, automatizan flujos de trabajo y se adaptan en tiempo real.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Aprendizajes y Conclusiones&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Varias sesiones destacaron por sus ideas prácticas y su mirada hacia adelante:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Serverless &amp;amp; Analítica en Tiempo Real:&lt;/strong&gt; Las mejores prácticas para Lambda y pipelines de datos en streaming siguen evolucionando, con un fuerte enfoque en optimización del rendimiento y reducción de latencia.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;IA + Datos de IoT:&lt;/strong&gt; La necesidad de datos limpios y unificados es cada vez más crítica a medida que las industrias confían en la IA para manejar enormes volúmenes de datos de IoT. Los principios de la manufactura inteligente ya se aplican en edificios inteligentes y más allá.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Chatbots Agénticos &amp;amp; Serverless AI:&lt;/strong&gt; Los talleres prácticos de Lambda y las sesiones sobre chatbots y analítica dejaron claro que AWS está impulsando aplicaciones de IA agéntica que no solo responden, sino que también actúan.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;GenAI + Digital Twins:&lt;/strong&gt; La IA generativa sigue dominando. Un tema central fue cómo integrarla con datasets existentes para potenciar soluciones de digital twins, especialmente en industrias como AEC, donde las lecciones de sectores más maduros en IA aceleran la adopción.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;La dirección general: &lt;strong&gt;AWS está invirtiendo fuertemente en IA, datos en tiempo real y estrategias de modernización&lt;/strong&gt; que atraviesan todas las industrias.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Comunidad y Conexiones&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbtckvf406ufimi2o3de4.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbtckvf406ufimi2o3de4.PNG" alt="dinner" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fenbpkcf18973i2i2tbu5.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fenbpkcf18973i2i2tbu5.JPG" alt="CB's" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Uno de los momentos más gratificantes llegó al final del Summit: reencontrarme con líderes de la comunidad de AWS, volver a conectar con colegas del &lt;strong&gt;AWS Community Builders program&lt;/strong&gt; y compartir una cena donde hablamos sobre la &lt;strong&gt;próxima gran iniciativa que queremos organizar juntos&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Momentos como este me recuerdan que AWS no se trata solo de tecnología. Se trata de personas, colaboración y de construir juntos una comunidad más fuerte.&lt;/p&gt;

&lt;p&gt;El AWS Summit Toronto 2025 nos mostró hacia dónde se dirige la nube: más rápida, más inteligente y más agéntica que nunca.&lt;/p&gt;

&lt;p&gt;Me encantaría escuchar de otros que asistieron: &lt;strong&gt;¿Cuáles fueron sus principales aprendizajes?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Y si no pudieron participar este año, síganme para más reflexiones sobre AWS, DevOps y Terraform — seguiré compartiendo aprendizajes y el espíritu de la comunidad. &lt;/p&gt;

</description>
      <category>agenticai</category>
      <category>awscommunity</category>
      <category>aws</category>
      <category>ai</category>
    </item>
    <item>
      <title>AWS Summit Toronto 2025: From Human Oversight to Agentic AI</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Fri, 12 Sep 2025 17:42:08 +0000</pubDate>
      <link>https://dev.to/aws-builders/aws-summit-toronto-2025-reflections-from-two-inspiring-days-1imb</link>
      <guid>https://dev.to/aws-builders/aws-summit-toronto-2025-reflections-from-two-inspiring-days-1imb</guid>
      <description>&lt;p&gt;Last week I had the chance to attend the &lt;strong&gt;AWS Summit Toronto 2025&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqtl9djkude8hwizc3jys.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqtl9djkude8hwizc3jys.jpeg" alt="Toronto" width="800" height="450"&gt;&lt;/a&gt;&lt;br&gt;
This year’s event was split into two parts:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Day 1 – Partner Summit&lt;/strong&gt;, dedicated to AWS partners.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Day 2 – Open Summit&lt;/strong&gt;, welcoming the entire AWS community.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Both days were packed with learning, inspiration, and future-looking announcements. But more than anything, it was a chance to connect with peers, with leaders, and with the wider AWS community.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Day 1 – Partner Summit Highlights&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Day one was all about partners and the deep dive into AWS’s latest portfolio. Topics included:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;The Anatomy of Speed&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Industry Solutions &amp;amp; Security&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Generative AI and Migration/Modernization&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;AWS Marketplace evolution&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The biggest spotlight was on &lt;strong&gt;Agentic AI&lt;/strong&gt;. AWS introduced a portfolio that connects tools like &lt;strong&gt;Amazon Q, AWS Transform, Amazon Connect, Nova models, and Bedrock&lt;/strong&gt;, all tied together with new SDKs and services to build intelligent agents.&lt;/p&gt;

&lt;p&gt;⚡ &lt;strong&gt;Key themes:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Flexibility with OSS and partner integrations.&lt;/li&gt;
&lt;li&gt;Customization guardrails to build responsibly.&lt;/li&gt;
&lt;li&gt;Vertical solutions for industries like SAP, Oracle, and mainframes.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AWS Transform&lt;/strong&gt; as the first agentic AI service for migration and modernization, with impressive results like faster documentation assessment and reduced licensing costs.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Day 2 – Open Summit Themes&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;The second day zoomed out into the future of cloud. The evolution was clear:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;From &lt;strong&gt;Generative AI assistants&lt;/strong&gt; → &lt;strong&gt;Generative AI agents&lt;/strong&gt; → to &lt;strong&gt;Agentic AI systems&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Less human oversight, more automation, and multi-agent systems capable of reasoning like humans.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This shift toward &lt;strong&gt;agentic AI&lt;/strong&gt; signals the next chapter in cloud, where workloads don’t just run in AWS, but make decisions, automate workflows, and adapt in real time.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Key Learnings and Takeaways&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Several sessions stood out for their practical insights and forward-looking themes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Serverless &amp;amp; Real-Time Analytics:&lt;/strong&gt; Best practices for Lambda and streaming data pipelines continue to evolve, with a strong focus on performance optimization and reducing latency.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;AI + IoT Data:&lt;/strong&gt; Clean, unified data structures are becoming critical as industries rely on AI to manage massive IoT datasets. Smart manufacturing principles are now being applied to smart buildings and beyond.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Agentic Chatbots &amp;amp; Serverless AI:&lt;/strong&gt; Hands-on Lambda workshops and sessions on analytics and chatbots made clear that AWS is pushing hard toward agentic AI applications that don’t just respond, but act.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;GenAI + Digital Twins:&lt;/strong&gt; Generative AI continues to dominate. A major theme was integrating GenAI with existing datasets to power digital twin solutions, especially in industries like AEC, where lessons from more mature tech sectors can accelerate adoption.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The overall direction: &lt;strong&gt;AWS is investing heavily in AI, real-time data, and modernization strategies&lt;/strong&gt; that cut across industries.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Community and Connections&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Feog61wk6snjzu7a1mik5.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Feog61wk6snjzu7a1mik5.PNG" alt="dinnertime" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fo47k8gicadfq0n1x23eu.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fo47k8gicadfq0n1x23eu.JPG" alt="CB" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;One of the most rewarding moments came at the end of the Summit: meeting leaders from the AWS community, reconnecting with peers from the &lt;strong&gt;AWS Community Builders program&lt;/strong&gt;, and sharing a dinner where we talked about the &lt;strong&gt;next big thing we want to organize together&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Moments like these remind me that AWS isn’t just about technology. It’s about people, collaboration, and building a stronger community together.&lt;/p&gt;

&lt;p&gt;The AWS Summit Toronto 2025 showed us where cloud is heading: faster, smarter, and more agentic than ever before.&lt;/p&gt;

&lt;p&gt;👉 I’d love to hear from others who attended: &lt;strong&gt;What were your top takeaways?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;And if you couldn’t make it this year, follow me for more AWS, DevOps, and Terraform reflections — I’ll keep sharing the lessons and the community spirit. 🚀&lt;/p&gt;

</description>
      <category>awsagenticai</category>
      <category>awsummittoronto</category>
      <category>awscommunity</category>
      <category>terraspacio</category>
    </item>
    <item>
      <title>Cómo Aprobar el Examen de AWS Solutions Architect Professional Como un Verdadero Pro</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Tue, 02 Sep 2025 18:47:07 +0000</pubDate>
      <link>https://dev.to/aws-espanol/como-aprobar-el-examen-de-aws-solutions-architect-professional-como-un-verdadero-pro-lf5</link>
      <guid>https://dev.to/aws-espanol/como-aprobar-el-examen-de-aws-solutions-architect-professional-como-un-verdadero-pro-lf5</guid>
      <description>&lt;p&gt;Imagina esto: después de meses de estudio, exámenes de práctica y algunos momentos de duda, finalmente presionas el botón de &lt;strong&gt;enviar&lt;/strong&gt;. Entonces la pantalla muestra las palabras que has estado esperando: &lt;/p&gt;

&lt;p&gt;&lt;em&gt;“¡Felicidades! Has aprobado el AWS Certified Solutions Architect – Professional.”&lt;/em&gt; 🎉&lt;/p&gt;

&lt;p&gt;Eso me pasó no hace mucho, y déjame decirte, la sensación fue como terminar una gran comida después de horas en la cocina — llena de alivio, orgullo y quizás hasta un poco de cansancio.&lt;/p&gt;

&lt;p&gt;Esta certificación no es cualquier cosa — se trata de dominar:&lt;br&gt;
🌐 Diseño de arquitecturas complejas en AWS&lt;br&gt;
🔒 Seguridad, cumplimiento y gobierno a escala&lt;br&gt;
⚙️ Optimización de costo, rendimiento y resiliencia&lt;br&gt;
🛠️ Migración y modernización de cargas de trabajo&lt;br&gt;
📊 Equilibrar decisiones con necesidades reales de negocio&lt;/p&gt;

&lt;p&gt;Pero aquí está el detalle: aprobar el examen no se trata solo de memorizar preguntas. Se trata de entender realmente &lt;strong&gt;cómo funciona AWS a gran escala&lt;/strong&gt;. Y para mí, dos temas destacaron más que cualquier otro:&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Service Control Policies (SCPs)&lt;/strong&gt; – las barandillas que mantienen tus cuentas de AWS seguras y consistentes.&lt;br&gt;
✅ &lt;strong&gt;Migraciones&lt;/strong&gt; – las estrategias que ayudan a mover cargas de trabajo a AWS sin interrumpir el negocio.&lt;/p&gt;

&lt;p&gt;En este artículo compartiré mis ideas sobre estas dos áreas. Lo mantendré simple, con analogías y ejemplos del mundo real que realmente puedes usar — Sé que muchos de ustedes están aprendiendo AWS en inglés, pero resulta mucho más fácil si lo estudiamos en nuestro idioma, o quizás apenas están comenzando en la nube. Y si ya eres un experto, piénsalo como un repaso refrescante con una nueva perspectiva.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Service Control Policies (SCPs) – La Parte Técnica&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Muy bien, veamos lo que dice la documentación de AWS sobre &lt;strong&gt;Service Control Policies (SCPs)&lt;/strong&gt; pero de una forma más fácil de digerir:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Parte de AWS Organizations&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;Las SCPs viven dentro de &lt;strong&gt;AWS Organizations&lt;/strong&gt;, el servicio que usas para manejar múltiples cuentas de AWS en un solo lugar.&lt;/li&gt;
&lt;li&gt;Importante: las SCPs solo funcionan si activas &lt;em&gt;“todas las características”&lt;/em&gt;. Si solo tienes la facturación consolidada, las SCPs no estarán disponibles.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Las SCPs No Otorgan Permisos&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;Esto es lo más importante: &lt;strong&gt;las SCPs no dan acceso&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Simplemente definen los &lt;strong&gt;límites máximos de permisos&lt;/strong&gt; que una cuenta puede tener.&lt;/li&gt;
&lt;li&gt;Ejemplo: si IAM dice “sí” pero SCP dice “no”, el resultado es &lt;strong&gt;no&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Jerarquía y Herencia&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;Las SCPs se pueden aplicar en el &lt;strong&gt;root&lt;/strong&gt;, a &lt;strong&gt;Organizational Units (OUs)&lt;/strong&gt; o a &lt;strong&gt;cuentas individuales&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Las reglas bajan en cascada: una SCP en root afecta todo; una SCP en un OU afecta todas las cuentas dentro de ese OU.&lt;/li&gt;
&lt;li&gt;Los permisos efectivos = la intersección de SCPs + IAM. Para que una acción funcione, debe estar permitida en toda la cadena.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Lista de Permitir vs Lista de Denegar&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Lista de Permitir (denegar por defecto):&lt;/strong&gt; Todo está denegado a menos que lo permitas. Muy estricto, mucho trabajo.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Lista de Denegar (permitir por defecto):&lt;/strong&gt; Todo está permitido a menos que lo deniegues. Más fácil de manejar y lo más común.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Impacto en Permisos&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;Las SCPs afectan a &lt;strong&gt;usuarios y roles IAM&lt;/strong&gt; en &lt;strong&gt;cuentas miembro&lt;/strong&gt;, incluso al usuario root.&lt;/li&gt;
&lt;li&gt;No afectan la cuenta de administración ni a los roles vinculados a servicios.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Control Centralizado&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Las SCPs ayudan a mantener las cuentas bajo control:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Bloqueando servicios específicos&lt;/li&gt;
&lt;li&gt;Restringiendo regiones&lt;/li&gt;
&lt;li&gt;Asegurando cumplimiento&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Buenas Prácticas&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;No empieces en root. Haz pruebas en un OU primero para evitar bloquear servicios críticos.&lt;/li&gt;
&lt;li&gt;Usa &lt;strong&gt;IAM last accessed data&lt;/strong&gt; o &lt;strong&gt;CloudTrail&lt;/strong&gt; para revisar uso antes de aplicar restricciones.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;🏠 La Analogía de la Casa Familiar (Root, OUs, SCPs)&lt;/strong&gt;
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Root = la casa de los padres.&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Cada OU = un dormitorio diferente.&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Cada cuenta = el niño que vive en ese dormitorio.&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Escenario 1: Denegar en Root (mala idea)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Los padres ponen candado al refri: “Nadie puede comer helado.”&lt;/li&gt;
&lt;li&gt;Aunque las reglas del niño digan que sí, la regla de la casa aplica → nadie come helado.&lt;/li&gt;
&lt;li&gt;Eso pasa si niegas en root: no hay excepciones.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Escenario 2: Root Full Access + Denegar en OU (mejor práctica)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Los padres dicen: “Todos pueden comer lo que sea.” (FullAWSAccess por defecto).&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Cada dormitorio (OU) pone sus propias reglas:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Niño #1 → No helado.&lt;/li&gt;
&lt;li&gt;Niño #2 → No dulces.&lt;/li&gt;
&lt;li&gt;Niño #3 → Acceso completo.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Si Niño #1 de repente necesita helado para un proyecto de la escuela, lo mueves al cuarto del Niño #3.&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Eso es denegar a nivel OU: flexible y más fácil de manejar.&lt;/p&gt;&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Escenario 3: Lista de Permitir en Root (demasiado estricto)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Los padres ponen un pizarrón gigante: “Solo pizza y manzanas permitidas.”&lt;/li&gt;
&lt;li&gt;Cada comida nueva = actualizar el pizarrón. Demasiado trabajo.&lt;/li&gt;
&lt;li&gt;Eso es una lista de permitir en root → alto mantenimiento.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;✅ &lt;strong&gt;La estrategia ganadora:&lt;/strong&gt; &lt;strong&gt;Root = deja FullAWSAccess. OU = aplica listas de denegar. Excepciones = mueve cuentas.&lt;/strong&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  &lt;strong&gt;Migraciones – Lo Que Necesitas Saber para el Examen AWS SAP&lt;/strong&gt;
&lt;/h1&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;1. Planeación de Migración&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Cuando AWS habla de migraciones, no significa solo “mueve todo a la nube y espera que funcione.” Quieren que lo hagas &lt;strong&gt;como un pro&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Descubre lo que tienes (servidores, bases de datos, apps).&lt;/li&gt;
&lt;li&gt;Agrupa las cosas lógicamente (aplicaciones, dependencias).&lt;/li&gt;
&lt;li&gt;Elige la estrategia correcta de migración (las famosas &lt;strong&gt;6 R’s&lt;/strong&gt;).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Esta etapa es como planear una mudanza familiar grande. No agarras cajas al azar — haces una lista, decides qué se va, qué se queda y qué se actualiza.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;2. AWS Application Discovery Service (ADS)&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Esta herramienta es tu &lt;strong&gt;inventario&lt;/strong&gt; antes de la mudanza. Escanea automáticamente tu entorno on-premises y recoge detalles de servidores, VMs, bases de datos e incluso conexiones de red.&lt;/p&gt;

&lt;p&gt;Tiene &lt;strong&gt;tres formas principales de recolectar datos&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Agentless Collector&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;No requiere instalar nada en cada servidor.&lt;/li&gt;
&lt;li&gt;Ideal para entornos VMware.&lt;/li&gt;
&lt;li&gt;Recolecta datos básicos: hostname, IP, CPU, RAM, uso de disco.&lt;/li&gt;
&lt;li&gt;Limitación: no ve procesos ni dependencias de red.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;&lt;strong&gt;Discovery Agent (basado en agente)&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Instalado en cada servidor.&lt;/li&gt;
&lt;li&gt;Da datos detallados: procesos, flujos de red, rendimiento.&lt;/li&gt;
&lt;li&gt;Perfecto para entender &lt;strong&gt;cómo se comunican los servidores&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;&lt;strong&gt;Importación basada en archivos&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cuando ya tienes un inventario de otro sistema.&lt;/li&gt;
&lt;li&gt;Lo importas directo a &lt;strong&gt;Migration Hub&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;📊 &lt;strong&gt;¿Qué pasa después del descubrimiento?&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Los datos van a tu &lt;strong&gt;Migration Hub Home Region&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Puedes agrupar servidores en aplicaciones.&lt;/li&gt;
&lt;li&gt;Exportar los datos a S3, Athena o QuickSight para análisis de costos.&lt;/li&gt;
&lt;li&gt;Usar la info para &lt;strong&gt;dimensionar bien EC2s&lt;/strong&gt; y planear costos.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;3. Servicios de Migración: De VMware u On-Prem a AWS&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Cuando ya tienes el plan, es hora de mover las cajas. Para el examen SAP, necesitas conocer estos servicios clave:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;AWS Application Migration Service (MGN)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;El &lt;strong&gt;campeón del lift-and-shift&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Replica servidores en AWS y los convierte en EC2s.&lt;/li&gt;
&lt;li&gt;Minimiza downtime.&lt;/li&gt;
&lt;li&gt;Funciona con &lt;strong&gt;Migration Hub&lt;/strong&gt; para seguimiento.&lt;/li&gt;
&lt;li&gt;Bonus: después de rehost, puedes replatform o refactor fácilmente.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;&lt;strong&gt;AWS Database Migration Service (DMS)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Especial para bases de datos.&lt;/li&gt;
&lt;li&gt;Soporta migraciones homogéneas (Oracle → Oracle) y heterogéneas (SQL Server → Aurora).&lt;/li&gt;
&lt;li&gt;Integra con &lt;strong&gt;Fleet Advisor&lt;/strong&gt; para planear migraciones de DB.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;&lt;strong&gt;AWS Migration Hub&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;El panel central de todos los proyectos de migración.&lt;/li&gt;
&lt;li&gt;Muestra el estado de servidores y apps, sin importar qué herramienta uses.&lt;/li&gt;
&lt;li&gt;Piensa en él como el &lt;strong&gt;coordinador de la mudanza&lt;/strong&gt; que rastrea cada camión y caja.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;4. Estrategias de Migración (Las 6 R’s)&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Estas seguro aparecen en el examen:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Rehost (Lift &amp;amp; Shift):&lt;/strong&gt; Mover tal cual. Ej: VM → EC2.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Replatform:&lt;/strong&gt; Pequeños cambios. Ej: App → Elastic Beanstalk, DB → RDS.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Refactor (Re-arquitectar):&lt;/strong&gt; Cambios grandes. Ej: Monolito → microservicios con Lambda.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Repurchase:&lt;/strong&gt; Reemplazar con SaaS. Ej: CRM on-prem → Salesforce.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Retire:&lt;/strong&gt; Dar de baja apps que no se usan.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Retain:&lt;/strong&gt; Mantener on-prem por ahora.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;✅ &lt;strong&gt;Conclusiones&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Service Control Policies (SCPs):&lt;/strong&gt; Son las barandillas de AWS Organizations. No dan acceso, pero definen los límites máximos de permisos. La mejor práctica: dejar FullAWSAccess en root y aplicar listas de denegar en OUs para flexibilidad y seguridad.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Migraciones:&lt;/strong&gt; No es solo levantar y mover servidores. Requiere planeación, descubrir con ADS, mover con MGN o DMS, dar seguimiento con Migration Hub y finalmente aplicar la estrategia adecuada de las 6 R’s. Así la migración es predecible y costo-eficiente.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;¡Eso es todo! 🎬 Ya viste dos de los temas más pesados del examen AWS SAP: &lt;strong&gt;SCPs&lt;/strong&gt; y &lt;strong&gt;Migraciones&lt;/strong&gt;. Ambos son críticos no solo para aprobar el examen, sino también para trabajar como un verdadero Solutions Architect en el mundo real.&lt;/p&gt;

&lt;p&gt;Si este artículo te ayudó, aquí está lo que puedes hacer después:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Sígueme en &lt;a href="https://x.com/TerraSpacio" rel="noopener noreferrer"&gt;X&lt;/a&gt; and &lt;a href="https://www.youtube.com/@TerraSpacio" rel="noopener noreferrer"&gt;YouTube&lt;/a&gt;&lt;/strong&gt; para más contenido de AWS, DevOps y Terraform, amigable para principiantes pero también útil para el examen.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Deja un comentario&lt;/strong&gt; con tus pensamientos, tu propio camino en el AWS SAP o preguntas que quieras que cubra después.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Pronto crearé un repositorio en GitHub.&lt;/strong&gt; donde compartiré recursos y ejemplos de práctica.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;¡Éxito en tu camino al AWS SAP, y recuerda: preparación + práctica = aprobar como un pro! 🚀&lt;/p&gt;

</description>
      <category>awssapcert</category>
      <category>awsscp</category>
      <category>awsmigracion</category>
      <category>estudiaaws</category>
    </item>
    <item>
      <title>How to Pass the AWS Solutions Architect Professional Certification Like a Real Pro</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Tue, 02 Sep 2025 17:20:50 +0000</pubDate>
      <link>https://dev.to/aws-builders/how-to-pass-the-aws-solutions-architect-professional-certification-like-a-real-pro-3j0j</link>
      <guid>https://dev.to/aws-builders/how-to-pass-the-aws-solutions-architect-professional-certification-like-a-real-pro-3j0j</guid>
      <description>&lt;p&gt;Imagine this: after months of studying, practice exams, and a few moments of doubt, you finally hit that submit button. Then the screen flashes with the words you’ve been waiting for: &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;“Congratulations, you have passed the AWS Certified Solutions Architect – Professional.”&lt;/strong&gt; 🎉&lt;/p&gt;

&lt;p&gt;That was me not long ago, and let me tell you, the feeling was just like finishing a big meal after hours in the kitchen. Full of relief, pride, and maybe even a little exhaustion.&lt;/p&gt;

&lt;h2&gt;
  
  
  This certification is no small feat it’s all about mastering:
&lt;/h2&gt;

&lt;p&gt;🌐 Designing complex architectures on AWS&lt;br&gt;
🔒 Security, compliance &amp;amp; governance at scale&lt;br&gt;
⚙️ Cost, performance &amp;amp; resilience optimization&lt;br&gt;
🛠️ Migration &amp;amp; modernization of workloads&lt;br&gt;
📊 Balancing trade-offs for real business needs&lt;/p&gt;

&lt;p&gt;But here’s the thing: passing the exam isn’t just about memorizing questions. It’s about really understanding how AWS works at scale. And for me, two topics stood out more than anything else:&lt;/p&gt;

&lt;p&gt;✅ Service Control Policies (SCPs) – the guardrails that keep your AWS accounts safe and consistent.&lt;br&gt;
✅ Migrations – the strategies that help move workloads to AWS without breaking the business.&lt;/p&gt;

&lt;p&gt;In this article, I’ll share my insights on these two areas. I’ll keep it simple, using real world analogies and examples that you can actually apply. Because I know many of you are learning AWS as a second language, or maybe just getting started in the cloud. And if you’re already an expert, consider this a refreshing walk through with a new perspective.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Service Control Policies (SCPs)&lt;/strong&gt; – the guardrails that keep your AWS accounts safe and consistent.&lt;br&gt;
✅ &lt;strong&gt;Migrations&lt;/strong&gt; – the strategies that help move workloads to AWS without breaking the business.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Service Control Policies (SCPs) – The Technical Part&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Alright, let’s break down what AWS documentation says about &lt;strong&gt;Service Control Policies (SCPs)&lt;/strong&gt; in a way that’s easier to digest:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Part of AWS Organizations&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SCPs live inside &lt;strong&gt;AWS Organizations&lt;/strong&gt;, which is the service you use to manage multiple AWS accounts in one place.&lt;/li&gt;
&lt;li&gt;Important: SCPs only work if you enable &lt;em&gt;“all features”&lt;/em&gt;. If you only have consolidated billing, SCPs won’t be available.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;SCPs Do Not Grant Permissions&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;This is the most important thing: &lt;strong&gt;SCPs don’t give access&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;They simply define the &lt;strong&gt;maximum permissions&lt;/strong&gt; an account can ever have.&lt;/li&gt;
&lt;li&gt;Example: if IAM says “yes” but SCP says “no,” the result is &lt;strong&gt;no&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Hierarchy and Inheritance&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SCPs can be attached at the &lt;strong&gt;root&lt;/strong&gt;, to &lt;strong&gt;Organizational Units (OUs)&lt;/strong&gt;, or to &lt;strong&gt;individual accounts&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Rules flow downward: a root SCP impacts everything; OU SCPs impact all accounts inside that OU.&lt;/li&gt;
&lt;li&gt;Effective permissions = intersection of SCPs + IAM. For an action to work, it must be allowed everywhere.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Allow List vs Deny List&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Allow List (deny by default):&lt;/strong&gt; Everything is denied unless you allow it. Very strict, lots of overhead.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Deny List (allow by default):&lt;/strong&gt; Everything is allowed unless you deny it. Easier to manage and most common.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Impact on Permissions&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SCPs affect &lt;strong&gt;IAM users and roles&lt;/strong&gt; in &lt;strong&gt;member accounts&lt;/strong&gt;, including the root user.&lt;/li&gt;
&lt;li&gt;They do &lt;strong&gt;not&lt;/strong&gt; affect the management account or service-linked roles.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Centralized Control&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;SCPs help organizations keep accounts under control by:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Blocking specific services&lt;/li&gt;
&lt;li&gt;Enforcing regional restrictions&lt;/li&gt;
&lt;li&gt;Ensuring compliance&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Best Practices&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Don’t start at the root. Test in an OU first to avoid blocking critical services.&lt;/li&gt;
&lt;li&gt;Use &lt;strong&gt;IAM last accessed data&lt;/strong&gt; or &lt;strong&gt;CloudTrail&lt;/strong&gt; to check usage before applying restrictions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;🏠 The Family House Analogy (Root, OUs, SCPs)&lt;/strong&gt;
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Root = the parents’ house.&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Each OU = a different child’s bedroom.&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Each account = the kid who lives in that bedroom.&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Scenario 1: Root Deny (bad idea)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Parents put a lock on the fridge: “Nobody can eat ice cream.”&lt;/li&gt;
&lt;li&gt;Even if one kid’s rules say they can, the house rule applies → no ice cream for anyone.&lt;/li&gt;
&lt;li&gt;That’s what happens if you deny at root: no exceptions possible.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Scenario 2: Root Full Access + OU Deny (best practice)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Parents say: “Everyone can eat anything.” (default FullAWSAccess).&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Each bedroom (OU) adds its own rules:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Kid #1 → No ice cream.&lt;/li&gt;
&lt;li&gt;Kid #2 → No candy.&lt;/li&gt;
&lt;li&gt;Kid #3 → Full access.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;&lt;p&gt;If Kid #1 suddenly needs ice cream for a school project, just move them into Kid #3’s room.&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;That’s OU-level deny: flexible and easier to manage.&lt;/p&gt;&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Scenario 3: Allow List at Root (too strict)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Parents put a giant whiteboard: “Only pizza and apples allowed.”&lt;/li&gt;
&lt;li&gt;Every new food = update the board. Too much work.&lt;/li&gt;
&lt;li&gt;That’s an allow list at root → high overhead.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;✅ &lt;strong&gt;In plain English:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Root deny = fridge locked for all, no exceptions.&lt;/li&gt;
&lt;li&gt;OU deny = bedroom rules, exceptions possible.&lt;/li&gt;
&lt;li&gt;Allow list = whiteboard nightmare.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;👉 The winning strategy: &lt;strong&gt;Root = leave FullAWSAccess. OU = apply deny lists. Exceptions = move accounts.&lt;/strong&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  &lt;strong&gt;Migrations&lt;/strong&gt; What You Need to Know for the AWS SAP Exam
&lt;/h1&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Migration Planning&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;When AWS talks about migrations, they don’t just mean “move everything to the cloud and hope it works.” They want you to &lt;strong&gt;plan like a pro&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Discover what you have (servers, databases, apps).&lt;/li&gt;
&lt;li&gt;Group things logically (applications, dependencies).&lt;/li&gt;
&lt;li&gt;Choose the right migration strategy (the famous &lt;strong&gt;6 R’s&lt;/strong&gt;).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This planning stage is like preparing for a big family move. You don’t just grab boxes randomly. You will make a list, decide what goes, what stays, and what needs upgrading. Right?&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;AWS Application Discovery Service (ADS)&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;This tool is your &lt;strong&gt;inventory manager&lt;/strong&gt; before moving day. It automatically scans your on premises environment and collects details about servers, VMs, databases, and even network connections.&lt;/p&gt;

&lt;p&gt;It has &lt;strong&gt;three main ways to discover data&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Agentless Collector&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;No need to install anything on each server.&lt;/li&gt;
&lt;li&gt;Great for VMware environments.&lt;/li&gt;
&lt;li&gt;Collects basic info: hostname, IP, CPU, RAM, disk usage.&lt;/li&gt;
&lt;li&gt;Limitation: cannot see running processes or network dependencies.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;&lt;strong&gt;Agent-based Discovery Agent&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Installed directly on each server.&lt;/li&gt;
&lt;li&gt;Provides deep insights: processes, network flows, performance data.&lt;/li&gt;
&lt;li&gt;Best if you need to understand &lt;strong&gt;how servers talk to each other&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;&lt;strong&gt;File-based Import&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;For when you already have an inventory from another system.&lt;/li&gt;
&lt;li&gt;You can import that data straight into &lt;strong&gt;Migration Hub&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;📊 &lt;strong&gt;What happens after discovery?&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Data is sent to your &lt;strong&gt;Migration Hub Home Region&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;You can group servers into applications.&lt;/li&gt;
&lt;li&gt;Export the data to S3, Athena, or QuickSight for cost analysis.&lt;/li&gt;
&lt;li&gt;Use the info to &lt;strong&gt;right size EC2 instances&lt;/strong&gt; and plan costs more accurately.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Migration Services: Moving from VMware or On-Prem to AWS&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Once planning is done, it’s time to move the boxes. For SAP exam purposes, you need to know the main AWS services:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;AWS Application Migration Service (MGN)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Think of this as the &lt;strong&gt;lift and shift champion&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;It replicates servers into AWS and automatically converts them into EC2 instances.&lt;/li&gt;
&lt;li&gt;Great for minimizing downtime.&lt;/li&gt;
&lt;li&gt;Works with &lt;strong&gt;Migration Hub&lt;/strong&gt; so you can track progress.&lt;/li&gt;
&lt;li&gt;Bonus: after rehosting, you can later replatform or refactor easily.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;&lt;strong&gt;AWS Database Migration Service (DMS)&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Specifically for migrating databases.&lt;/li&gt;
&lt;li&gt;Supports homogeneous migrations (Oracle → Oracle) and heterogeneous (SQL Server → Aurora).&lt;/li&gt;
&lt;li&gt;Also integrates with &lt;strong&gt;Fleet Advisor&lt;/strong&gt; to discover and plan DB migrations.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;&lt;strong&gt;AWS Migration Hub&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The central dashboard for all migration projects.&lt;/li&gt;
&lt;li&gt;Shows the status of servers and applications, regardless of which tool you use.&lt;/li&gt;
&lt;li&gt;Think of it like the &lt;strong&gt;moving company coordinator&lt;/strong&gt; that tracks every truck and box.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Migration Strategies (The 6 R’s)&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;You’ll definitely see these on the exam:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Rehost (Lift &amp;amp; Shift):&lt;/strong&gt; Move as-is. Example: VM → EC2.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Replatform:&lt;/strong&gt; Small changes. Example: App → Elastic Beanstalk, DB → RDS.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Refactor (Re-architect):&lt;/strong&gt; Big changes. Example: Monolith → microservices with Lambda.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Repurchase:&lt;/strong&gt; Replace with SaaS. Example: On-prem CRM → Salesforce.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Retire:&lt;/strong&gt; Decommission unused apps.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Retain:&lt;/strong&gt; Keep it on-prem for now.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;✅ &lt;strong&gt;Conclusions&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Service Control Policies (SCPs):&lt;/strong&gt; They are the guardrails of AWS Organizations. SCPs don’t give access but define the maximum boundaries of permissions. The best approach is to leave FullAWSAccess at the root and apply deny lists at the OU level for flexibility and safer management.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Migrations:&lt;/strong&gt; A successful migration is not just lifting and shifting servers. It requires planning, discovering your environment with ADS, moving workloads with MGN or DMS, tracking with Migration Hub, and finally applying the right strategy from the 6 R’s. With the right approach, migrations become predictable and cost-efficient.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That’s a wrap! 🎬 You’ve now seen two of the heaviest topics for the AWS SAP exam: &lt;strong&gt;SCPs&lt;/strong&gt; and &lt;strong&gt;Migrations&lt;/strong&gt;. Both are critical to not just passing the exam, but also working as a real Solutions Architect in the field.&lt;/p&gt;

&lt;p&gt;If this article helped you, here’s what you can do next:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Follow me on &lt;a href="https://x.com/TerraSpacio" rel="noopener noreferrer"&gt;X&lt;/a&gt; and &lt;a href="https://www.youtube.com/@TerraSpacio" rel="noopener noreferrer"&gt;YouTube&lt;/a&gt;&lt;/strong&gt; for more AWS, DevOps, and Terraform content that’s beginner-friendly but also exam-ready.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Leave a comment&lt;/strong&gt; with your thoughts, your own AWS SAP journey, or questions you’d like me to cover next.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Coming soon, a GitHub repo&lt;/strong&gt; where I’ll be sharing supporting resources and examples to practice with.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Good luck with your AWS SAP journey, and remember: preparation + practice = passing like a pro! &lt;/p&gt;

</description>
      <category>awscertification</category>
      <category>awssap</category>
      <category>awsmigrationandscp</category>
      <category>awscommunity</category>
    </item>
    <item>
      <title>Secure Your AWS Pipeline: Step-by-Step Guide to VPC Integration-part 2</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Thu, 20 Mar 2025 21:23:46 +0000</pubDate>
      <link>https://dev.to/aws-builders/secure-your-aws-pipeline-step-by-step-guide-to-vpc-integration-part-2-hdh</link>
      <guid>https://dev.to/aws-builders/secure-your-aws-pipeline-step-by-step-guide-to-vpc-integration-part-2-hdh</guid>
      <description>&lt;h1&gt;
  
  
  Welcome back!
&lt;/h1&gt;

&lt;p&gt;I hope you still have an appetite for learning more about CICD and how to secure your deployments. In Part 1, you built your first AWS CICD pipeline.  Awesome job, but as any great chef knows, it’s not just about making a delicious dish; you must also keep your kitchen organized and safe. &lt;/p&gt;

&lt;p&gt;Now that your pipeline is up and running, it’s time to take the next step: securing access to your private resources within a VPC and setting up proper permissions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;In this part, we’ll cover:&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;What is a VPC and why does it matter?&lt;/li&gt;
&lt;li&gt;How to securely connect your pipeline to a production environment in a private subnet?&lt;/li&gt;
&lt;/ul&gt;

&lt;h1&gt;
  
  
  Let’s dive right in! 🍽️
&lt;/h1&gt;

&lt;p&gt;&lt;strong&gt;What is a VPC and Why Does It Matter?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Before we start securing things, let’s talk about what a VPC (Virtual Private Cloud) is. Imagine your AWS environment as a massive restaurant kitchen. A VPC is like having separate workstations one for chopping, one for cooking, and one for plating. Each station (or subnet, I'll elaborate on this further shortly.) has its purpose, and you decide who gets access to each. &lt;/p&gt;

&lt;p&gt;A VPC allows you to create an isolated section in AWS where you can launch your resources securely. It’s like having a private kitchen that only your team can enter, keeping unwanted guests or security risks out. Within a VPC, you can set up public and private subnets to control where traffic flows, ensuring that sensitive infrastructure like databases stays protected from the outside world.&lt;/p&gt;

&lt;p&gt;Now that we’ve got a basic idea, let’s move on to securely connecting our pipeline to a private subnet. If you’re looking for a more technical explanation, I will include all the necessary documentation for further study in the sources section of this article series.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How to Securely Connect Your Pipeline to a Production Environment in a Private Subnet?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Let's imagine that your pipeline is like a chef sending prepared dishes to the right station. But what if the final plating area is in a private section of the restaurant? You need a secure way to get the food there without letting unauthorized people in. That’s where private subnets come in.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;You might be wondering, "What is a private subnet?"&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;A private subnet is an isolated area within your VPC that doesn’t have direct internet access. To allow your pipeline to deploy into a private subnet, you’ll need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A NAT Gateway or VPC Endpoint, This acts like a secure delivery pass, letting the pipeline reach private resources without exposing them to the public internet.&lt;/li&gt;
&lt;li&gt;Proper Security Group Rules, Think of these as access control rules that decide which resources can talk to each other.&lt;/li&gt;
&lt;li&gt;IAM Roles and Policies, You don’t want just anyone making changes in your environment. IAM roles ensure only the right processes have access to deploy inside the VPC.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In this second part, we will focus on building and using a NAT Gateway to enable secure updates for an application within a Private Subnet.&lt;/p&gt;

&lt;p&gt;So, your application lives in a private subnet, safe from the public internet, but wait, How do you update it? Private subnets don’t have direct internet access, which is great for security but tricky for getting updates. This is where a NAT Gateway comes in, acting like a controlled exit door.&lt;/p&gt;

&lt;p&gt;Think of it like a high end restaurant’s storage room. Only authorized staff can go in and out, ensuring that only fresh ingredients (updates) make their way into the kitchen without letting unwanted visitors (security threats) sneak in.&lt;/p&gt;

&lt;p&gt;By adding a NAT Gateway, your private instances can access the internet to download updates, pull dependencies, etc. while being shielded from direct exposure. &lt;strong&gt;Sounds exciting,Doesn't it?&lt;/strong&gt; and here’s how it works:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The NAT Gateway sits in a public subnet and has an Elastic IP assigned to it.&lt;/li&gt;
&lt;li&gt;A route table is configured so that private subnets send outbound traffic to the NAT Gateway instead of directly to the internet.&lt;/li&gt;
&lt;li&gt;The pipeline (running in CodePipeline) can now deploy updates to your private resources securely.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvjqev5f7g7yx5x48mdzy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvjqev5f7g7yx5x48mdzy.png" alt="VPC" width="800" height="449"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft8yuok4n6mesxw90zzro.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft8yuok4n6mesxw90zzro.png" alt="NATGATEWAY" width="800" height="673"&gt;&lt;/a&gt;&lt;br&gt;
Credits to AWS documentation[1]. &lt;/p&gt;

&lt;p&gt;At this point, you should have a solid high-level understanding of what a VPC is and how to protect your private resources. Now, let's explore how Terraform can enhance this configuration, making it even more secure with just a few lines of code.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Here’s what to expect when using this Terraform template:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;✅ Sets up a VPC&lt;br&gt;
✅ Creates public and private subnets&lt;br&gt;
✅ Configures a NAT Gateway for internet access from private subnets&lt;br&gt;
✅ Sets up route tables for proper traffic flow&lt;br&gt;
✅ Specifies Security Groups&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# Create a VPC
resource "aws_vpc" "main_vpc" {
  cidr_block = "10.0.0.0/16"
}

# Create Public and Private Subnets
resource "aws_subnet" "public_subnet" {
  vpc_id                  = aws_vpc.main_vpc.id
  cidr_block              = "10.0.1.0/24"
  map_public_ip_on_launch = true
}

resource "aws_subnet" "private_subnet" {
  vpc_id     = aws_vpc.main_vpc.id
  cidr_block = "10.0.2.0/24"
}

# Create an Internet Gateway for Public Subnet
resource "aws_internet_gateway" "gw" {
  vpc_id = aws_vpc.main_vpc.id
}

# Create a NAT Gateway for Private Subnet
resource "aws_eip" "nat_eip" {}

resource "aws_nat_gateway" "nat_gw" {
  allocation_id = aws_eip.nat_eip.id
  subnet_id     = aws_subnet.public_subnet.id
}

# Route Table for Public Subnet (Direct Internet Access)
resource "aws_route_table" "public_rt" {
  vpc_id = aws_vpc.main_vpc.id

  route {
    cidr_block = "0.0.0.0/0"
    gateway_id = aws_internet_gateway.gw.id
  }
}

resource "aws_route_table_association" "public_assoc" {
  subnet_id      = aws_subnet.public_subnet.id
  route_table_id = aws_route_table.public_rt.id
}

# Route Table for Private Subnet (Internet Access via NAT Gateway)
resource "aws_route_table" "private_rt" {
  vpc_id = aws_vpc.main_vpc.id

  route {
    cidr_block = "0.0.0.0/0"
    nat_gateway_id = aws_nat_gateway.nat_gw.id
  }
}

resource "aws_route_table_association" "private_assoc" {
  subnet_id      = aws_subnet.private_subnet.id
  route_table_id = aws_route_table.private_rt.id
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  What’s Next?
&lt;/h2&gt;

&lt;p&gt;With this setup, your CICD pipeline can securely deploy updates to resources in a private subnet while still having controlled internet access via a NAT Gateway. This means your private environment stays protected while getting the latest updates just like a top tier restaurant keeping its ingredients fresh without letting anyone walk in off the street.&lt;/p&gt;

&lt;h2&gt;
  
  
  Want to see it all in action?
&lt;/h2&gt;

&lt;p&gt;Complete this architectural deployment utilizing the full &lt;a href="https://github.com/ValAug/AWS-Pipeline-Step-by-Step-Guide-to-VPC-Integration?tab=readme-ov-file" rel="noopener noreferrer"&gt;GitHub Repository - Create a CICD Pipeline with Terraform AWS-Pipeline-Step-by-Step-Guide-to-VPC-Integration&lt;/a&gt;. You're welcome to browse through other projects I've worked using this &lt;a href="https://github.com/ValAug" rel="noopener noreferrer"&gt;link&lt;/a&gt;. And don’t forget to:&lt;/p&gt;

&lt;p&gt;✅ Follow me on &lt;a href="https://x.com/TerraSpacio" rel="noopener noreferrer"&gt;X&lt;/a&gt; and &lt;a href="https://www.youtube.com/@TerraSpacio" rel="noopener noreferrer"&gt;YouTube&lt;/a&gt; for more AWS, DevOps, and Terraform tips &lt;br&gt;
✅ Comment below with any questions or suggestions &lt;br&gt;
✅ Check out the GitHub repo for the full Terraform setup&lt;/p&gt;

&lt;p&gt;🚀 Happy building!&lt;/p&gt;

&lt;h3&gt;
  
  
  Sources:
&lt;/h3&gt;

&lt;p&gt;[1] &lt;a href="https://docs.aws.amazon.com/vpc/latest/userguide/nat-gateway-scenarios.html" rel="noopener noreferrer"&gt;https://docs.aws.amazon.com/vpc/latest/userguide/nat-gateway-scenarios.html&lt;/a&gt;&lt;br&gt;
[2] &lt;a href="https://docs.aws.amazon.com/vpc/latest/userguide/what-is-amazon-vpc.html" rel="noopener noreferrer"&gt;https://docs.aws.amazon.com/vpc/latest/userguide/what-is-amazon-vpc.html&lt;/a&gt;&lt;/p&gt;

</description>
      <category>awsproject</category>
      <category>terraform</category>
      <category>devops</category>
      <category>awssecurity</category>
    </item>
    <item>
      <title>Secure Your AWS Pipeline: Step-by-Step Guide to VPC Integration</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Thu, 23 Jan 2025 17:04:59 +0000</pubDate>
      <link>https://dev.to/aws-builders/secure-your-aws-pipeline-step-by-step-guide-to-vpc-integration-4n5i</link>
      <guid>https://dev.to/aws-builders/secure-your-aws-pipeline-step-by-step-guide-to-vpc-integration-4n5i</guid>
      <description>&lt;h3&gt;
  
  
  Why Automate?
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Picture this:&lt;/strong&gt; Your team just kicked off a brand new project. Everyone’s excited, but one big question is hanging over your head how will you deploy all this code? You’ve been asked to set up a pipeline to handle the process. At first, it sounds straightforward, but you start thinking about what’s involved: &lt;strong&gt;testing&lt;/strong&gt;, &lt;strong&gt;building&lt;/strong&gt;, and &lt;strong&gt;deploying&lt;/strong&gt; every time someone pushes a change. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Do you do it manually?&lt;/strong&gt;  That’s going to get messy fast.&lt;/p&gt;

&lt;p&gt;This is where automation steps in to save the day. With a CICD pipeline, all those repetitive tasks like testing and deploying are handled for you. It’s like having a reliable assistant who never gets tired or makes mistakes. And as someone stepping into a DevOps role, knowing how to set this up isn’t just helpful it’s essential.&lt;/p&gt;

&lt;p&gt;In this article, you’ll gain hands on experience building your first CICD pipeline using AWS CodePipeline and GitHub. Once your pipeline is set up, it will connect to private resources inside a VPC, ensuring secure deployment. You’ll also configure monitoring and an alarming system with CloudWatch and SNS topics to receive email notifications if a build fails, giving you a solid and dependable workflow from start to finish.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Now, let’s explore what CICD is all about. What is CICD?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;CICD stands for Continuous Integration and Continuous Deployment.&lt;/p&gt;

&lt;h3&gt;
  
  
  Let’s break it down:
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Continuous Integration (CI):&lt;/strong&gt; This is about automatically integrating code changes from multiple developers into a single project. Every time you push new code, the system checks if it works with the existing codebase by running tests.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Continuous Deployment (CD):&lt;/strong&gt; This step takes it further. After your code passes all tests, it gets deployed automatically to a live environment or staging environment.&lt;/p&gt;

&lt;p&gt;Think of CICD as a chef in a busy restaurant. You prepare the ingredients &lt;strong&gt;(your code)&lt;/strong&gt;, and instead of making each dish from start to finish yourself, you have a kitchen team &lt;strong&gt;(the pipeline)&lt;/strong&gt; handling the repetitive tasks like chopping, cooking, and plating. The result? Your dishes are prepared faster, consistently, and ready to be served &lt;strong&gt;(deployed)&lt;/strong&gt; to your customers without any unnecessary delays or errors. And hey, unlike a real kitchen, this pipeline never burns the toast 😎. Now that we’ve got the basics, let’s dive deeper into AWS CodePipeline.&amp;nbsp;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is AWS CodePipeline?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;AWS CodePipeline is an AWS service that helps you automate the software release process. It’s like having a reliable kitchen team working behind the scenes while you focus on crafting your signature dish. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Here’s why it’s a big deal:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Automation:&lt;/strong&gt; It takes care of repetitive tasks like building, testing, and deploying code for you.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Speed:&lt;/strong&gt; CodePipeline helps you roll out features and updates faster than ever.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Integration:&lt;/strong&gt; It plays nicely with tools like GitHub, CodeBuild, and other AWS services, making your workflow seamless and efficient.&lt;/p&gt;

&lt;p&gt;With AWS CodePipeline, you don’t need to worry about manually deploying changes. Instead, you can focus on improving your code and delivering value to your users. Think of it like having a sous chef who handles all the prep work for you, so you can focus on perfecting the final dish.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why Should You Care?
&lt;/h3&gt;

&lt;p&gt;Now, you might be wondering, &lt;strong&gt;Why does all this matter?&lt;/strong&gt; Well, as someone stepping into a DevOps role, your goal is to bridge the gap between development and operations. Knowing how to set up a CICD pipeline is critical because:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;It saves you time:&lt;/strong&gt; Automated pipelines handle repetitive tasks, so you can focus on creating better features.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;It reduces errors:&lt;/strong&gt; By automating testing and deployment, you minimize the risk of human error.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;It ensures consistency:&lt;/strong&gt; Every build and deployment follows the same process, leading to more reliable results.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;By understanding CICD and CodePipeline, you’re not just learning a skill; you're building a foundation for smoother, faster, and more reliable deployments. And here’s the &lt;strong&gt;exciting&lt;/strong&gt; part: you’ll be using &lt;strong&gt;Terraform&lt;/strong&gt; from start to finish to build this project, giving you a hands on experience with infrastructure as code. Before we jump in, let’s take a moment to understand the monitoring tools we’ll be &lt;strong&gt;using:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CloudWatch:&lt;/strong&gt; Think of this as the monitoring dashboard for your AWS resources. It keeps track of metrics, logs, and events, helping you spot and troubleshoot issues before they become bigger problems.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;SNS (Simple Notification Service):&lt;/strong&gt; This is the messenger. When something goes wrong like a pipeline build failure CloudWatch triggers an alarm, and SNS sends you an email (or another type of notification) to alert you. It’s like having an always on assistant keeping you in the loop.&lt;/p&gt;

&lt;p&gt;With these tools in place, we’ll keep an eye on operations and get immediate notifications if something breaks. Let’s get hands on and start building your first pipeline.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/ValAug/AWS-Pipeline-Step-by-Step-Guide-to-VPC-Integration?tab=readme-ov-file" rel="noopener noreferrer"&gt;GitHub Repository - Create a CICD Pipeline with Terraform Step-by-Step-Guide&lt;/a&gt; Set a reminder for the update or revisit this page in a few days. You're welcome to browse through other projects I've worked on in the meantime using this &lt;a href="https://github.com/ValAug" rel="noopener noreferrer"&gt;link&lt;/a&gt;.&lt;/p&gt;

&lt;h1&gt;
  
  
  Digram:
&lt;/h1&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8lkauvqhxd53g00xa13w.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8lkauvqhxd53g00xa13w.png" alt="CICD" width="800" height="433"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Code Previous:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;resource "aws_codebuild_project" "my_project" {
  name          = "my-codebuild-project"
  description   = "My CodeBuild project"
  service_role  = aws_iam_role.codebuild_role.arn
  source {
    type      = "GITHUB"
    location  = "https://github.com/your-repo.git"  # Replace with your GitHub repository
  }
  artifacts {
    type = "NO_ARTIFACTS"
  }
  environment {
    compute_type                = "BUILD_GENERAL1_SMALL"
    image                       = "aws/codebuild/standard:5.0"
    type                        = "LINUX_CONTAINER"
    environment_variable {
      name  = "ENV_VAR_NAME"
      value = "value"
    }
  }
}

resource "aws_codepipeline" "my_pipeline" {
  name     = "my-codepipeline"
  role_arn = aws_iam_role.codepipeline_role.arn

  artifact_store {
    location = "my-artifact-store"  # Replace with your S3 bucket name
    type     = "S3"
  }

  stage {
    name = "Source"
    action {
      name            = "Source"
      category        = "Source"
      owner           = "ThirdParty"
      provider        = "GitHub"
      version         = "1"
      output_artifacts = ["source_output"]

      configuration = {
        Owner  = "your-github-username"
        Repo   = "your-repo"
        Branch = "main"
        OAuthToken = "your-oauth-token"  # Replace with your GitHub OAuth token
      }
    }
  }

  stage {
    name = "Build"
    action {
      name            = "Build"
      category        = "Build"
      owner           = "AWS"
      provider        = "CodeBuild"
      version         = "1"
      input_artifacts = ["source_output"]
      output_artifacts = ["build_output"]

      configuration = {
        ProjectName = aws_codebuild_project.my_project.name
      }
    }
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You’ve done an awesome job getting through this. Give yourself a break—you’ve earned it. And here’s &lt;strong&gt;the exciting part:&lt;/strong&gt; this is just the beginning. In the next part of this series, we’ll dive into how to securely connect your pipeline to a production environment inside a subnet in a VPC. Plus, you’ll learn how to take security and automation to the next level.&lt;/p&gt;

&lt;p&gt;Meanwhile, follow me on &lt;a href="https://x.com/TerraSpacio" rel="noopener noreferrer"&gt;X&lt;/a&gt; and &lt;a href="https://www.youtube.com/@TerraSpacio" rel="noopener noreferrer"&gt;YouTube&lt;/a&gt; for more content about AWS, DevOps, and Terraform. I’d love to see what you create, so don’t hesitate to share your projects and questions. &lt;/p&gt;

&lt;p&gt;See you in the next part!&lt;/p&gt;

</description>
      <category>awscicd</category>
      <category>terraform</category>
      <category>awsvpc</category>
      <category>stepbystepguidetodevops</category>
    </item>
    <item>
      <title>Lee esto antes de implementar S3 y CloudFront usando Terraform.</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Tue, 31 Dec 2024 15:38:57 +0000</pubDate>
      <link>https://dev.to/aws-builders/lee-esto-antes-de-implementar-s3-y-cloudfront-usando-terraform-3399</link>
      <guid>https://dev.to/aws-builders/lee-esto-antes-de-implementar-s3-y-cloudfront-usando-terraform-3399</guid>
      <description>&lt;p&gt;En este artículo, imaginaremos que trabajas para una empresa que está a punto de lanzar una gran campaña de marketing para uno de sus productos más nuevos y esperan que miles de clientes visiten su sitio web. Tu gerente se puso en contacto contigo y compartió esta información, expresando que le gustaría que pensaras en cómo construir un diseño arquitectónico para este sitio web.&lt;/p&gt;

&lt;p&gt;&lt;iframe width="710" height="399" src="https://www.youtube.com/embed/rgshOqQAg3c"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

&lt;h2&gt;
  
  
  Hechos a considerar
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;La campaña de marketing es solo por unos días.&lt;/li&gt;
&lt;li&gt;La empresa no sabe cuántos espectadores atraerá esta campaña a su sitio web, pero pronostican miles para los primeros días después del lanzamiento de la campaña.&lt;/li&gt;
&lt;li&gt;Hay una gran preocupación por los ataques DoS/DDoS.&lt;/li&gt;
&lt;li&gt;Debe estar dentro de su presupuesto.&lt;/li&gt;
&lt;li&gt;Necesita ser accesible rápidamente desde cualquier lugar del mundo.&lt;/li&gt;
&lt;li&gt;Para el propósito de este artículo, te enfocarás más en el diseño arquitectónico donde puedes alojar tu sitio web para cumplir con los requisitos asignados para esta tarea y no tanto en el desarrollo del sitio web en sí.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Tener un sitio web es un tema candente, ya que cada negocio necesita uno. &lt;/p&gt;

&lt;p&gt;Podrías preguntarte, ¿dónde puedo alojar este sitio web?&lt;/p&gt;

&lt;p&gt;Permíteme presentarte dos poderosos servicios de AWS que pueden ayudarte a comenzar este proyecto asegurando una distribución global del contenido del sitio web:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AWS CloudFront&lt;/li&gt;
&lt;li&gt;AWS S3&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Diagrama: CloudFront y S3.
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fon85ibhp7dncisl9gcsx.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fon85ibhp7dncisl9gcsx.png" alt="Diagrama" width="800" height="403"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  ¿Qué método utilizaremos para desplegar esta infraestructura?
&lt;/h2&gt;

&lt;p&gt;Desplegaremos esta infraestructura como código (IaC) utilizando Terraform.&lt;/p&gt;

&lt;h2&gt;
  
  
  ¿Qué es Terraform y por qué es tan útil?
&lt;/h2&gt;

&lt;p&gt;"Terraform es una herramienta para construir, cambiar y versionar infraestructura de forma segura y eficiente. Terraform puede gestionar proveedores de servicios existentes y populares, así como soluciones personalizadas internas."&lt;/p&gt;

&lt;p&gt;Terraform es una poderosa herramienta declarativa que nos ayuda a gestionar una gran mayoría de servicios en la nube, además de proporcionar consistencia y visibilidad de los cambios en la infraestructura que ocurren en diferentes espacios de trabajo y entornos. Esta funcionalidad no solo mejora la calidad de vida de nuestros proyectos, sino que también mantiene informados a los ingenieros de software y a otros miembros del equipo.&lt;/p&gt;

&lt;p&gt;Ten en cuenta que podemos crear o configurar cualquier servidor de AWS a través de la consola de gestión de AWS, pero el problema es que lleva tiempo si haces lo mismo una y otra vez. Al usar Terraform, no necesitamos iniciar sesión en la consola de gestión de AWS y podemos terminar nuestro trabajo solo con la línea de comandos.&lt;/p&gt;

&lt;p&gt;En este proyecto encontrarás dos módulos. Un módulo te ayudará a desplegar un bucket S3 para almacenar tus archivos web y también utilizará el punto final del sitio web del bucket S3 desde la función de alojamiento de sitios web estáticos, sirviendo como origen con CloudFront como CDN.&lt;/p&gt;

&lt;p&gt;El segundo te ayudará a desplegar buckets S3 para almacenar tus archivos web, pero esta vez CloudFront servirá como CDN así como un origen. Recomiendo el segundo módulo, ya que no necesitarías habilitar el alojamiento de sitios web estáticos en tu bucket porque esta infraestructura utilizará un punto final de API REST del bucket en lugar del punto final del sitio web de la función de alojamiento de sitios web estáticos.&lt;/p&gt;

&lt;h2&gt;
  
  
  Plantillas de Terraform:
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# --- s3_module main file

resource "random_string" "bucket_rs" {
  count   = var.s3_count
  length  = 4
  special = false
  upper   = false

}
resource "aws_s3_bucket" "exos_bucket" {
  count = var.s3_count
  bucket = join("-", ["exos-bucket", random_string.bucket_rs[count.index].result])
  acl    = "public-read-write"
}

resource "aws_cloudfront_distribution" "exos_distribution" {
  count = var.s3_count
  origin {

    custom_origin_config {
      http_port = "80"
      https_port = "443"
      origin_protocol_policy = "match-viewer"
      origin_ssl_protocols = ["TLSv1", "TLSv1.1", "TLSv1.2"]

    }

    domain_name = aws_s3_bucket.exos_bucket[count.index].bucket_regional_domain_name
    origin_id = "exos_distribution"

  }

  enabled = true
  default_root_object = "index.html"

  default_cache_behavior {
    viewer_protocol_policy = "redirect-to-https"
    compress = true
    allowed_methods = ["GET", "HEAD", "OPTIONS", "PUT", "POST", "PATCH", "DELETE"]
    cached_methods = ["GET", "HEAD"]
    target_origin_id = "exos_distribution"
    min_ttl                = 0
    default_ttl            = 86400
    max_ttl                = 31536000




    forwarded_values {
      query_string = false
      cookies {
        forward = "none"
      }
    }

  }

  price_class = "PriceClass_All"

  restrictions {
    geo_restriction {
      restriction_type = "whitelist"
      locations        = ["US", "CA", "GB", "DE"]
    }

  }

  viewer_certificate {
    cloudfront_default_certificate = true
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  ¿Qué es CloudFront?
&lt;/h2&gt;

&lt;p&gt;"CloudFront es un servicio de Red de Entrega de Contenido (CDN) rápido. CloudFront proporcionará a nuestro proyecto una red distribuida global que servirá como caché de contenido, como imágenes, videos y archivos estáticos desde centros de datos distribuidos llamados ubicaciones de borde."&lt;/p&gt;

&lt;p&gt;Mientras CloudFront mejora la experiencia del usuario al entregar contenido estático, también puede ser utilizado para gestionar múltiples solicitudes de usuarios mientras entrega excelentes servicios a los clientes. Pero las características de CloudFront no terminan aquí. Tiene increíbles características de seguridad integradas, como la mitigación de ataques DoS/DDoS, la Identidad de Acceso de Origen (OAI), que utilizaremos para controlar sin problemas el acceso a nuestros buckets S3. También podemos usar la función de geolocalización en la distribución de CloudFront, que puede ayudarnos a servir nuestro contenido dentro de ciertas regiones o países. Hay más características que esto, pero para el propósito de este artículo mencionaré solo algunas.&lt;/p&gt;

&lt;p&gt;Un punto interesante a mencionar es que entregar contenido a través de CloudFront será más rentable cuando el número de solicitudes crezca en comparación con S3, así como cuando los datos transferidos entre los servicios de AWS y CloudFront no estén sujetos al costo de transferencia de datos.&lt;/p&gt;

&lt;h2&gt;
  
  
  ¿Qué es S3?
&lt;/h2&gt;

&lt;p&gt;"Amazon Simple Storage Service (Amazon S3) es un servicio de almacenamiento de objetos que ofrece escalabilidad, disponibilidad de datos, seguridad y rendimiento líderes en la industria."&lt;/p&gt;

&lt;p&gt;Además de ser un servicio de almacenamiento de objetos, S3 también puede alojar sitios web estáticos con técnicas del lado del cliente, como HTML, CSS y JavaScript, que no requieren scripts del lado del servidor, como PHP o ASP.NET.&lt;/p&gt;

&lt;p&gt;El aspecto más fácil de tener S3 como un bucket de alojamiento de sitios web es que no necesitaremos solicitar un formulario para alojar nuestro sitio web estático ni pagar ningún costo inicial. Una vez que el sitio web estático de S3 esté configurado, se generará automáticamente un punto final de sitio web de Amazon S3 para el bucket. Utilizaremos el punto final del sitio web para probar la velocidad y el rendimiento.&lt;/p&gt;

&lt;p&gt;Otro punto importante de ahorro de costos es que, en lugar de ejecutar servidores web como Nginx o Apache en instancias EC2, que pueden ser costosos, podemos alojar los archivos estáticos en S3.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://calculator.s3.amazonaws.com/index.html" rel="noopener noreferrer"&gt;Enlace al calculador mensual simple de S3 aquí&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Velocidad de entrega de DNS de contenido utilizando el punto final del sitio web de CloudFront frente al punto final del sitio web de S3.&lt;/p&gt;

&lt;h2&gt;
  
  
  Usando AWS CloudFront name.cloudfront.net frente a bucketname-x23x.s3.amazonaws.com puntuación de rendimiento.
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fawlm2s21m4ygozhhhoqc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fawlm2s21m4ygozhhhoqc.png" alt="Alt Text" width="781" height="175"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  El mapa de solicitudes muestra cada una de las ubicaciones desde las cuales se perfiló el sitio web.
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7y69xldrxi7e74funpki.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7y69xldrxi7e74funpki.png" alt="Alt Text" width="676" height="360"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F27dfofbqad78p7ztlh92.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F27dfofbqad78p7ztlh92.png" alt="Alt Text" width="683" height="371"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Puntuaciones de rendimiento promedio proporcionan una visión básica del tiempo de ida y vuelta de cualquier ubicación.
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fabdc214vpcca3n6cwkl6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fabdc214vpcca3n6cwkl6.png" alt="Alt Text" width="674" height="380"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusión
&lt;/h2&gt;

&lt;p&gt;Ambos servicios, AWS CloudFront y AWS S3, se complementan entre sí y pueden ofrecerte un espacio poderoso para alojar tu sitio web y vale la pena intentarlo.&lt;/p&gt;

&lt;h2&gt;
  
  
  Beneficios de usar S3 y CloudFront:
&lt;/h2&gt;

&lt;p&gt;Velocidad CDN más rápida con CloudFront.&lt;br&gt;
Bajo costo de almacenamiento con S3 y transferencia de datos gratuita a CloudFront. Fuerte seguridad para ambos.&lt;/p&gt;

&lt;p&gt;Es importante señalar que esta infraestructura puede ser más robusta al agregar otros servidores como AWS WAF, AWS Shield o Route53, que probablemente agregaré en un artículo posterior 😊.&lt;/p&gt;

&lt;p&gt;Tener Terraform en la mezcla facilita la creación, destrucción de recursos, pruebas y depuración de tus proyectos.&lt;/p&gt;

&lt;p&gt;Este proyecto de Terraform está diseñado dinámicamente para desplegar uno o más buckets S3 según tus requisitos. También crea una asociación de CDN de CloudFront para cada bucket.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/ValAug/S3_CloudFront_Webdeployment" rel="noopener noreferrer"&gt;Encuentra el repositorio de Terraform y las direcciones para este proyecto aquí&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  ¿Listo para optimizar tus implementaciones de AWS?
&lt;/h2&gt;

&lt;p&gt;Comienza a usar Terraform para gestionar tu infraestructura como código. Experimenta con el código proporcionado y comparte tus experiencias en los comentarios. Si te gustó este artículo, sígueme para más contenido sobre AWS y Terraform.&lt;/p&gt;

&lt;p&gt;Tu participación es valiosa, y me encantaría saber de tus comentarios.&lt;/p&gt;

</description>
      <category>aws</category>
      <category>terraform</category>
      <category>s3</category>
      <category>cloudfront</category>
    </item>
    <item>
      <title>Lee esto antes de implementar S3 y CloudFront usando Terraform.</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Tue, 31 Dec 2024 15:31:49 +0000</pubDate>
      <link>https://dev.to/aws-espanol/lee-esto-antes-de-implementar-s3-y-cloudfront-usando-terraform-4ia</link>
      <guid>https://dev.to/aws-espanol/lee-esto-antes-de-implementar-s3-y-cloudfront-usando-terraform-4ia</guid>
      <description>&lt;p&gt;En este artículo, imaginaremos que trabajas para una empresa que está a punto de lanzar una gran campaña de marketing para uno de sus productos más nuevos y esperan que miles de clientes visiten su sitio web. Tu gerente se puso en contacto contigo y compartió esta información, expresando que le gustaría que pensaras en cómo construir un diseño arquitectónico para este sitio web.&lt;/p&gt;

&lt;p&gt;&lt;iframe width="710" height="399" src="https://www.youtube.com/embed/rgshOqQAg3c"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

&lt;h2&gt;
  
  
  Hechos a considerar
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;La campaña de marketing es solo por unos días.&lt;/li&gt;
&lt;li&gt;La empresa no sabe cuántos espectadores atraerá esta campaña a su sitio web, pero pronostican miles para los primeros días después del lanzamiento de la campaña.&lt;/li&gt;
&lt;li&gt;Hay una gran preocupación por los ataques DoS/DDoS.&lt;/li&gt;
&lt;li&gt;Debe estar dentro de su presupuesto.&lt;/li&gt;
&lt;li&gt;Necesita ser accesible rápidamente desde cualquier lugar del mundo.&lt;/li&gt;
&lt;li&gt;Para el propósito de este artículo, te enfocarás más en el diseño arquitectónico donde puedes alojar tu sitio web para cumplir con los requisitos asignados para esta tarea y no tanto en el desarrollo del sitio web en sí.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Tener un sitio web es un tema candente, ya que cada negocio necesita uno. &lt;/p&gt;

&lt;p&gt;Podrías preguntarte, ¿dónde puedo alojar este sitio web?&lt;/p&gt;

&lt;p&gt;Permíteme presentarte dos poderosos servicios de AWS que pueden ayudarte a comenzar este proyecto asegurando una distribución global del contenido del sitio web:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AWS CloudFront&lt;/li&gt;
&lt;li&gt;AWS S3&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Diagrama: CloudFront y S3.
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fon85ibhp7dncisl9gcsx.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fon85ibhp7dncisl9gcsx.png" alt="Diagrama" width="800" height="403"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  ¿Qué método utilizaremos para desplegar esta infraestructura?
&lt;/h2&gt;

&lt;p&gt;Desplegaremos esta infraestructura como código (IaC) utilizando Terraform.&lt;/p&gt;

&lt;h2&gt;
  
  
  ¿Qué es Terraform y por qué es tan útil?
&lt;/h2&gt;

&lt;p&gt;"Terraform es una herramienta para construir, cambiar y versionar infraestructura de forma segura y eficiente. Terraform puede gestionar proveedores de servicios existentes y populares, así como soluciones personalizadas internas."&lt;/p&gt;

&lt;p&gt;Terraform es una poderosa herramienta declarativa que nos ayuda a gestionar una gran mayoría de servicios en la nube, además de proporcionar consistencia y visibilidad de los cambios en la infraestructura que ocurren en diferentes espacios de trabajo y entornos. Esta funcionalidad no solo mejora la calidad de vida de nuestros proyectos, sino que también mantiene informados a los ingenieros de software y a otros miembros del equipo.&lt;/p&gt;

&lt;p&gt;Ten en cuenta que podemos crear o configurar cualquier servidor de AWS a través de la consola de gestión de AWS, pero el problema es que lleva tiempo si haces lo mismo una y otra vez. Al usar Terraform, no necesitamos iniciar sesión en la consola de gestión de AWS y podemos terminar nuestro trabajo solo con la línea de comandos.&lt;/p&gt;

&lt;p&gt;En este proyecto encontrarás dos módulos. Un módulo te ayudará a desplegar un bucket S3 para almacenar tus archivos web y también utilizará el punto final del sitio web del bucket S3 desde la función de alojamiento de sitios web estáticos, sirviendo como origen con CloudFront como CDN.&lt;/p&gt;

&lt;p&gt;El segundo te ayudará a desplegar buckets S3 para almacenar tus archivos web, pero esta vez CloudFront servirá como CDN así como un origen. Recomiendo el segundo módulo, ya que no necesitarías habilitar el alojamiento de sitios web estáticos en tu bucket porque esta infraestructura utilizará un punto final de API REST del bucket en lugar del punto final del sitio web de la función de alojamiento de sitios web estáticos.&lt;/p&gt;

&lt;h2&gt;
  
  
  Plantillas de Terraform:
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# --- s3_module main file

resource "random_string" "bucket_rs" {
  count   = var.s3_count
  length  = 4
  special = false
  upper   = false

}
resource "aws_s3_bucket" "exos_bucket" {
  count = var.s3_count
  bucket = join("-", ["exos-bucket", random_string.bucket_rs[count.index].result])
  acl    = "public-read-write"
}

resource "aws_cloudfront_distribution" "exos_distribution" {
  count = var.s3_count
  origin {

    custom_origin_config {
      http_port = "80"
      https_port = "443"
      origin_protocol_policy = "match-viewer"
      origin_ssl_protocols = ["TLSv1", "TLSv1.1", "TLSv1.2"]

    }

    domain_name = aws_s3_bucket.exos_bucket[count.index].bucket_regional_domain_name
    origin_id = "exos_distribution"

  }

  enabled = true
  default_root_object = "index.html"

  default_cache_behavior {
    viewer_protocol_policy = "redirect-to-https"
    compress = true
    allowed_methods = ["GET", "HEAD", "OPTIONS", "PUT", "POST", "PATCH", "DELETE"]
    cached_methods = ["GET", "HEAD"]
    target_origin_id = "exos_distribution"
    min_ttl                = 0
    default_ttl            = 86400
    max_ttl                = 31536000




    forwarded_values {
      query_string = false
      cookies {
        forward = "none"
      }
    }

  }

  price_class = "PriceClass_All"

  restrictions {
    geo_restriction {
      restriction_type = "whitelist"
      locations        = ["US", "CA", "GB", "DE"]
    }

  }

  viewer_certificate {
    cloudfront_default_certificate = true
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  ¿Qué es CloudFront?
&lt;/h2&gt;

&lt;p&gt;"CloudFront es un servicio de Red de Entrega de Contenido (CDN) rápido. CloudFront proporcionará a nuestro proyecto una red distribuida global que servirá como caché de contenido, como imágenes, videos y archivos estáticos desde centros de datos distribuidos llamados ubicaciones de borde."&lt;/p&gt;

&lt;p&gt;Mientras CloudFront mejora la experiencia del usuario al entregar contenido estático, también puede ser utilizado para gestionar múltiples solicitudes de usuarios mientras entrega excelentes servicios a los clientes. Pero las características de CloudFront no terminan aquí. Tiene increíbles características de seguridad integradas, como la mitigación de ataques DoS/DDoS, la Identidad de Acceso de Origen (OAI), que utilizaremos para controlar sin problemas el acceso a nuestros buckets S3. También podemos usar la función de geolocalización en la distribución de CloudFront, que puede ayudarnos a servir nuestro contenido dentro de ciertas regiones o países. Hay más características que esto, pero para el propósito de este artículo mencionaré solo algunas.&lt;/p&gt;

&lt;p&gt;Un punto interesante a mencionar es que entregar contenido a través de CloudFront será más rentable cuando el número de solicitudes crezca en comparación con S3, así como cuando los datos transferidos entre los servicios de AWS y CloudFront no estén sujetos al costo de transferencia de datos.&lt;/p&gt;

&lt;h2&gt;
  
  
  ¿Qué es S3?
&lt;/h2&gt;

&lt;p&gt;"Amazon Simple Storage Service (Amazon S3) es un servicio de almacenamiento de objetos que ofrece escalabilidad, disponibilidad de datos, seguridad y rendimiento líderes en la industria."&lt;/p&gt;

&lt;p&gt;Además de ser un servicio de almacenamiento de objetos, S3 también puede alojar sitios web estáticos con técnicas del lado del cliente, como HTML, CSS y JavaScript, que no requieren scripts del lado del servidor, como PHP o ASP.NET.&lt;/p&gt;

&lt;p&gt;El aspecto más fácil de tener S3 como un bucket de alojamiento de sitios web es que no necesitaremos solicitar un formulario para alojar nuestro sitio web estático ni pagar ningún costo inicial. Una vez que el sitio web estático de S3 esté configurado, se generará automáticamente un punto final de sitio web de Amazon S3 para el bucket. Utilizaremos el punto final del sitio web para probar la velocidad y el rendimiento.&lt;/p&gt;

&lt;p&gt;Otro punto importante de ahorro de costos es que, en lugar de ejecutar servidores web como Nginx o Apache en instancias EC2, que pueden ser costosos, podemos alojar los archivos estáticos en S3.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://calculator.s3.amazonaws.com/index.html" rel="noopener noreferrer"&gt;Enlace al calculador mensual simple de S3 aquí&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Velocidad de entrega de DNS de contenido utilizando el punto final del sitio web de CloudFront frente al punto final del sitio web de S3.&lt;/p&gt;

&lt;h2&gt;
  
  
  Usando AWS CloudFront name.cloudfront.net frente a bucketname-x23x.s3.amazonaws.com puntuación de rendimiento.
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fawlm2s21m4ygozhhhoqc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fawlm2s21m4ygozhhhoqc.png" alt="Alt Text" width="781" height="175"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  El mapa de solicitudes muestra cada una de las ubicaciones desde las cuales se perfiló el sitio web.
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7y69xldrxi7e74funpki.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7y69xldrxi7e74funpki.png" alt="Alt Text" width="676" height="360"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F27dfofbqad78p7ztlh92.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F27dfofbqad78p7ztlh92.png" alt="Alt Text" width="683" height="371"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Puntuaciones de rendimiento promedio proporcionan una visión básica del tiempo de ida y vuelta de cualquier ubicación.
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fabdc214vpcca3n6cwkl6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fabdc214vpcca3n6cwkl6.png" alt="Alt Text" width="674" height="380"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusión
&lt;/h2&gt;

&lt;p&gt;Ambos servicios, AWS CloudFront y AWS S3, se complementan entre sí y pueden ofrecerte un espacio poderoso para alojar tu sitio web y vale la pena intentarlo.&lt;/p&gt;

&lt;h2&gt;
  
  
  Beneficios de usar S3 y CloudFront:
&lt;/h2&gt;

&lt;p&gt;Velocidad CDN más rápida con CloudFront.&lt;br&gt;
Bajo costo de almacenamiento con S3 y transferencia de datos gratuita a CloudFront. Fuerte seguridad para ambos.&lt;/p&gt;

&lt;p&gt;Es importante señalar que esta infraestructura puede ser más robusta al agregar otros servidores como AWS WAF, AWS Shield o Route53, que probablemente agregaré en un artículo posterior 😊.&lt;/p&gt;

&lt;p&gt;Tener Terraform en la mezcla facilita la creación, destrucción de recursos, pruebas y depuración de tus proyectos.&lt;/p&gt;

&lt;p&gt;Este proyecto de Terraform está diseñado dinámicamente para desplegar uno o más buckets S3 según tus requisitos. También crea una asociación de CDN de CloudFront para cada bucket.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/ValAug/S3_CloudFront_Webdeployment" rel="noopener noreferrer"&gt;Encuentra el repositorio de Terraform y las direcciones para este proyecto aquí&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  ¿Listo para optimizar tus implementaciones de AWS?
&lt;/h2&gt;

&lt;p&gt;Comienza a usar Terraform para gestionar tu infraestructura como código. Experimenta con el código proporcionado y comparte tus experiencias en los comentarios. Si te gustó este artículo, sígueme para más contenido sobre AWS y Terraform.&lt;/p&gt;

&lt;p&gt;Tu participación es valiosa, y me encantaría saber de tus comentarios.&lt;/p&gt;

</description>
      <category>aws</category>
      <category>terraform</category>
      <category>s3</category>
      <category>cloudfront</category>
    </item>
    <item>
      <title>Una Guía para Principiantes sobre la Autenticación usando API Gateway y Lambda Authorizer</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Sat, 21 Dec 2024 17:15:56 +0000</pubDate>
      <link>https://dev.to/aws-espanol/una-guia-para-principiantes-sobre-la-autenticacion-del-api-gateway-lambda-authorizer-e0i</link>
      <guid>https://dev.to/aws-espanol/una-guia-para-principiantes-sobre-la-autenticacion-del-api-gateway-lambda-authorizer-e0i</guid>
      <description>&lt;p&gt;Entender cómo autenticar usuarios a través de un API Gateway puede ser un desafío, pero es una habilidad esencial para los desarrolladores, especialmente cuando se trata de proveedores de identidad (IdPs) como Okta o Active Directory. Esta guía proporciona una explicación clara, paso a paso, del flujo de autenticación utilizando un Lambda Authorizer, facilitando su comprensión para los principiantes.&lt;/p&gt;

&lt;h2&gt;
  
  
  Historia
&lt;/h2&gt;

&lt;p&gt;Imagina que te estás preparando para una entrevista de trabajo en una empresa de tecnología, y el entrevistador te pregunta cómo manejar la autenticación de usuarios en una arquitectura sin servidor. Conocer el flujo de autenticación con un API Gateway y un Lambda Authorizer es crucial. Vamos a desglosarlo en partes manejables.&lt;/p&gt;

&lt;h3&gt;
  
  
  El Flujo de Autenticación
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Autenticación del Usuario&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;El proceso comienza cuando un usuario ingresa su ID de usuario y contraseña en un formulario de inicio de sesión. Envía estas credenciales a un IdP, como Okta o Active Directory.&lt;br&gt;
Si las credenciales son válidas, el IdP autentica al usuario y devuelve un token (a menudo un JSON Web Token, o JWT). Este token sirve como prueba de que el usuario ha sido autenticado con éxito.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Llamada a la API con Token&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;A continuación, el usuario desea acceder a un recurso a través del API Gateway. Para hacerlo, incluye el token recibido en el encabezado de su solicitud a la API.&lt;/p&gt;

&lt;p&gt;Este token es esencial porque le dice al API Gateway que el usuario es quien dice ser. Sin este token, la solicitud será denegada.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Lambda Authorizer para Validación&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;Dado que no estás utilizando AWS Cognito y en su lugar dependes de un IdP, se utiliza un Lambda Authorizer. Este es un código personalizado que escribes para validar el token.&lt;br&gt;
Cuando el API Gateway recibe la solicitud, invoca el Lambda Authorizer. El autorizer extrae el token del encabezado de la solicitud y verifica su validez comunicándose con el IdP.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Autorización con Políticas IAM&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;Una vez que se valida el token, el Lambda Authorizer también determina qué acciones puede realizar el usuario. Esto se hace especificando políticas IAM dentro del autorizer.&lt;/p&gt;

&lt;p&gt;Estas políticas IAM dictan qué recursos de AWS puede acceder el usuario y qué acciones puede realizar. Por ejemplo, un usuario podría tener permiso para leer datos de una base de datos, pero no para escribir en ella. Luego, el API Gateway verifica estas políticas con AWS IAM para asegurar el cumplimiento.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Invocación del Backend&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;Si la política IAM permite la acción solicitada, el API Gateway procede a invocar el servicio backend previsto, que podría ser otra función Lambda, un servicio de AWS o cualquier otro recurso.&lt;br&gt;
En esta etapa, la solicitud del usuario se procesa y recibe la respuesta deseada.&lt;/p&gt;
&lt;h3&gt;
  
  
  Nota Especial
&lt;/h3&gt;

&lt;p&gt;Es importante recordar que el Lambda Authorizer no necesita validar el token para cada llamada a la API. Para mejorar el rendimiento y reducir la latencia, puedes implementar un caché para las respuestas del autorizer. Esto significa que una vez que se valida un token, las solicitudes posteriores con el mismo token pueden procesarse más rápido.&lt;/p&gt;

&lt;p&gt;Comprender este flujo de autenticación es vital para cualquier persona que trabaje con arquitecturas sin servidor. Tómate el tiempo para familiarizarte con cada paso, practica explicar el proceso y considera construir un pequeño proyecto que implemente estos conceptos. Este conocimiento no solo te ayudará en las entrevistas, sino que también te empoderará en aplicaciones del mundo real.&lt;/p&gt;
&lt;h3&gt;
  
  
  Plantilla de Terraform
&lt;/h3&gt;

&lt;p&gt;Para ayudarte a implementar este flujo, aquí tienes una plantilla básica de Terraform que configura un API Gateway con un Lambda Authorizer:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight hcl"&gt;&lt;code&gt;  &lt;span class="nx"&gt;provider&lt;/span&gt; &lt;span class="s2"&gt;"aws"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;region&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"us-west-2"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_lambda_function"&lt;/span&gt; &lt;span class="s2"&gt;"authorizer"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;function_name&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"LambdaAuthorizer"&lt;/span&gt;
    &lt;span class="nx"&gt;handler&lt;/span&gt;       &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"authorizer.handler"&lt;/span&gt;
    &lt;span class="nx"&gt;runtime&lt;/span&gt;       &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"nodejs14.x"&lt;/span&gt;
    &lt;span class="nx"&gt;role&lt;/span&gt;          &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_iam_role&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;lambda_exec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;arn&lt;/span&gt;
    &lt;span class="nx"&gt;source_code_hash&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;filebase64sha256&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"authorizer.zip"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_iam_role"&lt;/span&gt; &lt;span class="s2"&gt;"lambda_exec"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;name&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"lambda_exec_role"&lt;/span&gt;
    &lt;span class="nx"&gt;assume_role_policy&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;jsonencode&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
      &lt;span class="nx"&gt;Version&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"2012-10-17"&lt;/span&gt;
      &lt;span class="nx"&gt;Statement&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[{&lt;/span&gt;
        &lt;span class="nx"&gt;Action&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"sts:AssumeRole"&lt;/span&gt;
        &lt;span class="nx"&gt;Principal&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
          &lt;span class="nx"&gt;Service&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"lambda.amazonaws.com"&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="nx"&gt;Effect&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"Allow"&lt;/span&gt;
        &lt;span class="nx"&gt;Sid&lt;/span&gt;    &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;""&lt;/span&gt;
      &lt;span class="p"&gt;}]&lt;/span&gt;
    &lt;span class="p"&gt;})&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_api_gateway_rest_api"&lt;/span&gt; &lt;span class="s2"&gt;"api"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;name&lt;/span&gt;        &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"MyAPI"&lt;/span&gt;
    &lt;span class="nx"&gt;description&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"API Gateway con Lambda Authorizer"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_api_gateway_resource"&lt;/span&gt; &lt;span class="s2"&gt;"resource"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;rest_api_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_rest_api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="nx"&gt;parent_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_rest_api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;root_resource_id&lt;/span&gt;
    &lt;span class="nx"&gt;path_part&lt;/span&gt;   &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"example"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_api_gateway_method"&lt;/span&gt; &lt;span class="s2"&gt;"method"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;rest_api_id&lt;/span&gt;   &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_rest_api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="nx"&gt;resource_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_resource&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;resource&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="nx"&gt;http_method&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"GET"&lt;/span&gt; &lt;span class="nx"&gt;authorization&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"CUSTOM"&lt;/span&gt;
    &lt;span class="nx"&gt;authorizer_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_authorizer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;authorizer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_api_gateway_authorizer"&lt;/span&gt; &lt;span class="s2"&gt;"authorizer"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;rest_api_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_rest_api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="nx"&gt;name&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"MyLambdaAuthorizer"&lt;/span&gt;
    &lt;span class="nx"&gt;authorizer_uri&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"${aws_lambda_function.authorizer.invoke_arn}"&lt;/span&gt;
    &lt;span class="nx"&gt;type&lt;/span&gt;        &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"REQUEST"&lt;/span&gt;
    &lt;span class="nx"&gt;identity_source&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"method.request.header.Authorization"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;output&lt;/span&gt; &lt;span class="s2"&gt;"api_endpoint"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;value&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"${aws_api_gateway_rest_api.api.invoke_url}/example"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Aquí encontrarás el repositorio de GitHub que contiene el código y las instrucciones.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/ValAug" rel="noopener noreferrer"&gt;Repositorio de GitHub - ¡Próximamente!&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;¿Listo para optimizar tus implementaciones de AWS?&lt;/p&gt;

&lt;p&gt;Comienza a usar Terraform para gestionar tu infraestructura como código. Experimenta con el código proporcionado y comparte tus experiencias en los comentarios. Si te gustó este artículo, sígueme para más contenido sobre AWS y Terraform.&lt;/p&gt;

&lt;p&gt;Tu participación es valiosa, y me encantaría saber de ti.&lt;/p&gt;

</description>
      <category>awsapigateway</category>
      <category>awslambdaauthorizer</category>
      <category>terraform</category>
      <category>proyectoserverless</category>
    </item>
    <item>
      <title>A Beginners Guide to Serverless API Gateway Authentication with Lambda Authorizer</title>
      <dc:creator>Augusto Valdivia</dc:creator>
      <pubDate>Sat, 21 Dec 2024 16:51:56 +0000</pubDate>
      <link>https://dev.to/aws-builders/a-beginners-guide-to-serverless-api-gateway-authentication-with-lambda-authorizer-1ach</link>
      <guid>https://dev.to/aws-builders/a-beginners-guide-to-serverless-api-gateway-authentication-with-lambda-authorizer-1ach</guid>
      <description>&lt;p&gt;Understanding how to authenticate users via an API Gateway can be a challenging yet essential skill for developers, especially when dealing with third-party identity providers (IdPs) like Okta or Active Directory. This guide provides a clear, step-by-step explanation of the authentication flow using a Lambda Authorizer, making it easy for beginners to grasp.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Authentication Flow
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;User Authentication&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;The process begins when users enter their user ID and password into a login form. They send these credentials to a third-party IdP, such as Okta or Active Directory.&lt;br&gt;
If the credentials are valid, the IdP authenticates the user and returns a token (often a JSON Web Token, or JWT). This token serves as proof that the user has been successfully authenticated.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;API Call with Token&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;Next, the user wants to access a resource via the API Gateway. To do this, they include the received token in the header of their API request.&lt;br&gt;
This token is essential because it tells the API Gateway that the user is who they claim to be. Without this token, the request will be denied.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Lambda Authorizer for Validation&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;Since you are not using AWS Cognito and are instead relying on a third-party IdP, a Lambda Authorizer comes into play. This is a custom piece of code that you write to validate the token.&lt;br&gt;
When the API Gateway receives the request, it invokes the Lambda Authorizer. The authorizer extracts the token from the request header and checks its validity by communicating with the third-party IdP.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Authorization with IAM Policies&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;Once the token is validated, the Lambda Authorizer also determines what actions the user is allowed to perform. This is done by specifying IAM policies within the authorizer.&lt;br&gt;
These IAM policies dictate what AWS resources the user can access and what actions they can perform. For example, a user might have permission to read data from a database but not to write to it. The API Gateway then checks these policies against AWS IAM to ensure compliance.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Backend Invocation&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;If the IAM policy allows the requested action, the API Gateway proceeds to invoke the intended backend service, which could be another Lambda function, an AWS service, or any other resource.&lt;br&gt;
At this stage, the user’s request is processed, and they receive the desired response.&lt;/p&gt;
&lt;h3&gt;
  
  
  Special Note
&lt;/h3&gt;

&lt;p&gt;It’s important to remember that the Lambda Authorizer does not need to validate the token for every single API call. To enhance performance and reduce latency, you can implement caching for the authorizer’s responses. This means that once a token is validated, subsequent requests with the same token can be processed faster.&lt;/p&gt;

&lt;p&gt;Understanding this authentication flow is vital for anyone working with serverless architectures. Take the time to familiarize yourself with each step, practice explaining the process, and consider building a small project that implements these concepts. This knowledge will not only help you in interviews but will also empower you in real-world applications.&lt;/p&gt;
&lt;h3&gt;
  
  
  Terraform Template
&lt;/h3&gt;

&lt;p&gt;To help you implement this flow, here’s a basic &lt;strong&gt;previous Terraform template&lt;/strong&gt; that sets up an API Gateway with a Lambda Authorizer:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight hcl"&gt;&lt;code&gt;  &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_api_gateway_rest_api"&lt;/span&gt; &lt;span class="s2"&gt;"api"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;name&lt;/span&gt;        &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"MyAPI"&lt;/span&gt;
    &lt;span class="nx"&gt;description&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"API Gateway with Lambda Authorizer"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_api_gateway_resource"&lt;/span&gt; &lt;span class="s2"&gt;"resource"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;rest_api_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_rest_api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="nx"&gt;parent_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_rest_api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;root_resource_id&lt;/span&gt;
    &lt;span class="nx"&gt;path_part&lt;/span&gt;   &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"example"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_api_gateway_method"&lt;/span&gt; &lt;span class="s2"&gt;"method"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;rest_api_id&lt;/span&gt;   &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_rest_api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="nx"&gt;resource_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_resource&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;resource&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="nx"&gt;http_method&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"GET"&lt;/span&gt; &lt;span class="nx"&gt;authorization&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"CUSTOM"&lt;/span&gt;
    &lt;span class="nx"&gt;authorizer_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_authorizer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;authorizer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="nx"&gt;resource&lt;/span&gt; &lt;span class="s2"&gt;"aws_api_gateway_authorizer"&lt;/span&gt; &lt;span class="s2"&gt;"authorizer"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;rest_api_id&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;aws_api_gateway_rest_api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;api&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt; &lt;span class="nx"&gt;name&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"MyLambdaAuthorizer"&lt;/span&gt;
    &lt;span class="nx"&gt;authorizer_uri&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"${aws_lambda_function.authorizer.invoke_arn}"&lt;/span&gt;
    &lt;span class="nx"&gt;type&lt;/span&gt;        &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"REQUEST"&lt;/span&gt;
    &lt;span class="nx"&gt;identity_source&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"method.request.header.Authorization"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;output&lt;/span&gt; &lt;span class="s2"&gt;"api_endpoint"&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;value&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"${aws_api_gateway_rest_api.api.invoke_url}/example"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here you will find the GitHub repository containing the code and instructions.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/ValAug" rel="noopener noreferrer"&gt;GitHub Repository - Coming Soon!&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Ready to streamline your AWS deployments?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Start using Terraform to manage your infrastructure as code. Experiment with the provided code and share your experiences in the comments. If you liked this article, follow me for more content on AWS and Terraform.&lt;/p&gt;

&lt;p&gt;Your participation is valuable, and I would love to hear from you.&lt;/p&gt;

</description>
      <category>apigatewayauthentication</category>
      <category>beginnersguidetoserverless</category>
      <category>terraform</category>
      <category>awslambda</category>
    </item>
  </channel>
</rss>
