diff --git a/external/Makefile b/external/Makefile index 84d2f95b..873edec6 100644 --- a/external/Makefile +++ b/external/Makefile @@ -6,11 +6,12 @@ default: apply terraform login terraform.tfvars: - ansible-playbook tfvars.yml + cp terraform.tfvars.example ${@} + nvim ${@} .terraform.lock.hcl: ~/.terraform.d/credentials.tfrc.json versions.tf terraform.tfvars terraform init - touch .terraform.lock.hcl + touch ${@} namespaces: ansible-playbook namespaces.yml diff --git a/external/terraform.tfvars.example b/external/terraform.tfvars.example new file mode 100644 index 00000000..8e47cbf0 --- /dev/null +++ b/external/terraform.tfvars.example @@ -0,0 +1,9 @@ +# https://dash.cloudflare.com/profile +cloudflare_email = "myaccount@example.com" +# https://developers.cloudflare.com/fundamentals/setup/find-account-and-zone-ids +cloudflare_account_id = "foobarid" +# https://dash.cloudflare.com/profile/api-tokens +cloudflare_api_key = "foobarkey" + +# https://my.zerotier.com/account +zerotier_central_token = "foobartoken" diff --git a/external/terraform.tfvars.j2 b/external/terraform.tfvars.j2 deleted file mode 100644 index 0e761dae..00000000 --- a/external/terraform.tfvars.j2 +++ /dev/null @@ -1,4 +0,0 @@ -cloudflare_email = "{{ cloudflare_email }}" -cloudflare_api_key = "{{ cloudflare_api_key }}" -cloudflare_account_id = "{{ cloudflare_account_id }}" -zerotier_central_token = "{{ zerotier_central_token }}" diff --git a/external/tfvars.yml b/external/tfvars.yml deleted file mode 100644 index 1c42d732..00000000 --- a/external/tfvars.yml +++ /dev/null @@ -1,18 +0,0 @@ -- name: Bootstrap external secrets - hosts: localhost - vars_prompt: - - name: cloudflare_email - prompt: Enter Cloudflare email - private: false - - name: cloudflare_api_key - prompt: Enter Cloudflare API Key (sensitive) - - name: cloudflare_account_id - prompt: Enter Cloudflare account ID - private: false - - name: zerotier_central_token - prompt: Enter ZeroTier Central API Token - tasks: - - name: Render environment file - template: - src: ./terraform.tfvars.j2 - dest: ./terraform.tfvars