From 16ea61883032ee5dac1250045c99836a80779158 Mon Sep 17 00:00:00 2001 From: lavenderguitar Date: Thu, 10 Feb 2022 01:02:29 -0500 Subject: [PATCH] v1.1 - Add linode object storage backend --- README.md | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 3f4a88c..cf769c0 100644 --- a/README.md +++ b/README.md @@ -15,9 +15,20 @@ _Hint: If configured properly using the provided setup, a different set of stati ### Initialize Linode Infrastructure - Terraform -First, clone the repo. Then `cd terraform/`. From here, use the following commands to connect Terraform to the Linode account: +First, clone the repo. Then `cd terraform/`. From here, create a `.envrc` file to load a few custom variables into your shell using `direnv`: - echo "export TF_VAR_token=<>" >> .envrc ## Add this manually, don't put your token in a CLI history. + + export TF_VAR_token=TF_VAR_token=<> + export TF_VAR_root_pass=<> + export AWS_ACCESS_KEY_ID=<> + export AWS_SECRET_ACCESS_KEY=<> + +Replace the name and region names in `backend.tf` to match the bucket created to store the .tfstate file. + +Use `direnv` to load the vars and Terraform to the Linode account: + + echo "export TF_VAR_token=<>" >> .envrc ## Add this manually, don't put a token in a CLI history. + direnv allow terraform init