Skip to content

iamdinegro/digitalocean-kubernetes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MarineGEO circle logo

MarineGEO circle logo

DOKS com Terraform

Nesse projeto, quero apresentar para vocês o Deploy de um Cluster DOKS (ou Digital Ocean Kubernetes Service), que é o serviço gerenciado de Kubernetes da DigitalOcean.

Estrutura dos arquivos do Terraform:

└── terraform
  |── main.tf
  |-─ network_vpc.tf
  |── provider.tf

Requisitos:

1 - Digital Ocean Api Token (PAT); 2 - Space Criado para Armazenar o BackEnd do Terraform; 3 - Spaces access key e Secret.

#####Na hora de iniciar o projeto, utilize o seguinte comando:

terraform init -var   \
"do_token=xxxxxxxxxx" \ 
-backend-config="access_key=xxxxx" \
-backend-config="secret_key=xxxxxxxxxx" \
-backend-config="bucket=<nomedospace>"

Retorno esperado:

Initializing the backend...

Initializing provider plugins...
- Reusing previous version of digitalocean/digitalocean from the dependency lock file
- Using previously-installed digitalocean/digitalocean v2.19.0

Terraform has been successfully initialized!

You may now begin working with Terraform. Try running "terraform plan" to see
any changes that are required for your infrastructure. All Terraform commands
should now work.

If you ever set or change modules or backend configuration for Terraform,
rerun this command to reinitialize your working directory. If you forget, other
commands will detect it and remind you to do so if necessary.

About

DigitalOcean Kubernetes with Terraform

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages