You don't have access to this class

Keep learning! Join and start boosting your career

Aprovecha el precio especial y haz tu profesión a prueba de IA

Antes: $249

Currency
$209
Suscríbete

Termina en:

2 Días
11 Hrs
37 Min
27 Seg

Interpolación, condiciones y ciclos

16/27
Resources

Remember that to tell Terraform our file with the variable values we run the command:

terraform plan -var-file your_file.tfvars

If we name our variables file .auto.tfvars it will no longer be necessary to pass the -var-file parameter to Terraform.

Dynamics

Using the reserved word dynamic we can iterate over an object so that Terraform sets up several similar resources.

Contributions 11

Questions 2

Sort by:

Want to see more contributions, questions and answers from the community?

Se agradece la claridad, pero con el lateral y terminal cerrados podríamos ver mejor el código.

Esta es la precedencia de como terraform lee las variables:

  • Environment variables
  • The terraform.tfvars file, if present.
  • The terraform.tfvars.json file, if present.
  • Any *.auto.tfvars or *.auto.tfvars.json files, processed in lexical order of their filenames.
  • Any -var and -var-file options on the command line, in the order they are provided. (This includes variables set by a Terraform Cloud workspace.)

variable-definition-precedence

Command: fmt
Dar formato al codigo en terraform con el comando
$ terraform fmt
mas informacion aquí

No olvidar: Si tengo variables que no van a cambiar nunca las declaro en el archivo name.auto.tsvars y si mis variables dependen de terceros en el archivo name.tsvars

Por qué no oculta la terminal cuando va explicando durante todo el video? A caso nadie se dio cuenta?

No se entendio nada para que sirven los bloques de: Ingress, se deberia explicar un poco mejor. Gracias

resource "aws_resource" "name_resource" { 
  name: "instance name"
}

aws_resource: resource de aws, los recursos que aws proporciona, basicamente todo lo que puedes hacer en la consola de aws esta disponible como recurso de terraform https://registry.terraform.io/providers/hashicorp/aws/latest/docs

name_resource: este nombre es para usar dentro de los archivos de definicion de terraform, puedes usar en un resource el valor que otro resouce entrega, por ejemplo aws_resource.name_resource.id devuelve el id del recurso y lo puedes usar para asignarlo a otro recurso

name: es el nombre que puedes ver al entrar a la consola de tu provedor de servicio (aws) para mantener organizacion en la infra estrucura, basicamente es el nombre de la instancia ya creada

No podían grabar en pantalla completa ?

No sabia qué significaba el [protocol = “-1”] :
protocol - (Required) Protocol. If you select a protocol of -1 (semantically equivalent to all, which is not a valid value here), you must specify a from_port and to_port equal to 0. The supported values are defined in the IpProtocol argument on the IpPermission API reference. This argument is normalized to a lowercase value to match the AWS API requirement when using with Terraform 0.12.x and above, please make sure that the value of the protocol is specified as lowercase when using with older version of Terraform to avoid an issue during upgrade.
Documentación:
https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/security_group#ingress

Se ve mucho panel y poco el código