[WIP] Update minimum required Terraform version and resolve various deprecation notices #22
+132
−87
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In order to update the AWS provider version (see the note at the bottom), we need to use a newer version of Terraform (1.4.5). However, this version doesn't support the deprecated
hashicorp/templateprovider on non-Intel Macs. (See discussions here and here.) A temporary workaround is to install the Intel version of Terraform, but this is annoying to set up, and the deprecated code needs to be updated anyway.This PR makes the following changes:
template_fileprovider with the built-intemplatefilefunction.Some of these changes already existed upstream. The others were added in controlshift#41
Due to the change in how the S3 bucket resources are defined, we need to run the following import commands BEFORE
terraform applyso that Terraform knows these resources already exist (otherwise it will try to delete and recreate them). Note:GLUE_SCRIPTS_BUCKET_NAMEandMANIFEST_BUCKET_NAMEmust be replaced with the actual S3 bucket names.The import commands update the Terraform state file that is saved in S3 and which represents the current state of the deployed infrastructure. After running the imports, run
terraform planand check the following:0 to destroyaws_s3_bucketresources should show~ update in-placeIf you want to examine the state file itself, you can use
terraform state listto list the resources addresses andterraform state show [RESOURCE_ADDRESS]to show the state details for the given resource.--
Items to be implemented separately due to their complexity:
glue_job.tf) would be nice to have.