Im encountering the following error in section 3.2 in particular terraform init part would throw the following error. Can anyone advise please?
got the following error after running terraform plan
module.landing_etl.data.aws_iam_policy_document.glue_base_policy: Reading…
module.landing_etl.data.aws_iam_role.glue_role: Reading…
module.landing_etl.data.aws_security_group.db_sg: Reading…
module.landing_etl.data.aws_subnet.public_a: Reading…
module.landing_etl.data.aws_iam_policy_document.glue_access_policy: Reading…
module.landing_etl.data.aws_iam_policy_document.glue_base_policy: Read complete after 0s [id=3940084333]
module.landing_etl.data.aws_iam_policy_document.glue_access_policy: Read complete after 0s [id=133058508]
Changes to Outputs:
- project = “”
You can apply this plan to save these new output values to the Terraform state, without changing any real infrastructure.
╷
│ Error: reading IAM Role (): operation error IAM: GetRole, https response error StatusCode: 400, RequestID: 220e4233-e4f5-46bc-8d7b-27a3d03a2afc, api error ValidationError: The specified value for roleName is invalid. It must contain only alphanumeric characters and/or the following: +=,.@_-
│
│ with module.landing_etl.data.aws_iam_role.glue_role,
│ on modules/landing_etl/iam_roles.tf line 1, in data “aws_iam_role” “glue_role”:
│ 1: data “aws_iam_role” “glue_role” {
│
╵
╷
│ Error: multiple EC2 Subnets matched; use additional constraints to reduce matches to a single EC2 Subnet
│
│ with module.landing_etl.data.aws_subnet.public_a,
│ on modules/landing_etl/network.tf line 1, in data “aws_subnet” “public_a”:
│ 1: data “aws_subnet” “public_a” {
│
╵
╷
│ Error: multiple EC2 Security Groups matched; use additional constraints to reduce matches to a single EC2 Security Group
│
│ with module.landing_etl.data.aws_security_group.db_sg,
│ on modules/landing_etl/network.tf line 5, in data “aws_security_group” “db_sg”:
│ 5: data “aws_security_group” “db_sg” {
│
╵
Hello @Edmund_Koh,
I couldn’t reproduce the issue, but I had simillar errors in other labs of the course. I suggest to wait for a new lab session (2 hours) to see if you can get terraform plan to work. You can also try to start from the beginning, delete terraform folder then click help and get latest version to get a new folder, finally click reboot, hope it helps: