aws-samples / amazon-autoscaling-mac1metal-ec2-with-terraform

MIT No Attribution
10 stars 9 forks source link

Error: Provider produced inconsistent final plan #3

Open josephburnett opened 1 year ago

josephburnett commented 1 year ago

When running terraform -chdir=terraform-aws-ec2-mac apply -var-file="my.tfvars" -auto-approve from https://aws.amazon.com/blogs/compute/implementing-autoscaling-for-ec2-mac-instances/ I got this warning and error:

╷
│ Warning: Redundant ignore_changes element
│
│   on main.tf line 117, in resource "aws_launch_template" "mac_workers":
│  117: resource "aws_launch_template" "mac_workers" {
│
│ Adding an attribute name to ignore_changes tells Terraform to ignore future changes to the argument in configuration after the object has been created,
│ retaining the value originally configured.
│
│ The attribute latest_version is decided by the provider alone and therefore there can be no configured value to compare with. Including this attribute in
│ ignore_changes has no effect. Remove the attribute from ignore_changes to quiet this warning.
╵
╷
│ Error: Provider produced inconsistent final plan
│
│ When expanding the plan for aws_autoscaling_group.mac_workers to include new values learned so far during apply, provider
│ "registry.terraform.io/hashicorp/aws" produced an invalid new value for .tags: length changed from 1 to 2.
│
│ This is a bug in the provider, which should be reported in the provider's own issue tracker.
╵

I tried again and it gave me this error:

╷
│ Error: Error creating Auto Scaling Group: ValidationError: You must use a valid fully-formed launch template. An instance is associated with one or more unshared license configurations. Disassociate unshared license configurations from the instance before proceeding with instance launch. Consult License Manager Documentation to learn more.
│       status code: 400, request id: 5ae1e95b-3930-46c2-a162-d5fe2b5b875b
│
│   with aws_autoscaling_group.mac_workers,
│   on main.tf line 189, in resource "aws_autoscaling_group" "mac_workers":
│  189: resource "aws_autoscaling_group" "mac_workers" {
│
╵

So I can't complete the setup. Is something in this template out of date?

josephburnett commented 1 year ago
% terraform --version
Terraform v1.3.4
on darwin_arm64