O'Reilly logo

Getting Started with Terraform - Second Edition by Kirill Shirinkin

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Static credentials

With this method, you just hardcode your access keys right inside your template. It looks as follows:

    provider "aws" {
        access_key = "xxxxxxxxxxxxx"
        secret_key = "xxxxxxxxxxxxx"
        region = "us-east-1"
    }

Though the simplest one, it is also the least flexible and secure. You don't want to give your credentials just like this to everyone in the team. Rather, each team member should use his or her own keys. Consider this method a bad practice and avoid it when possible.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required