Hi I am trying to setup Metaflow using the terrafo...
# dev-metaflow
a
Hi I am trying to setup Metaflow using the terraform example. When setting up the
metaflow
directory I am getting the following errors:
Copy code
╷
│ Error: no matching SecurityGroup found
│ 
│   with module.metaflow.module.metaflow-computation.data.aws_security_group.vpc_default,
│   on .terraform/modules/metaflow/modules/computation/data.tf line 11, in data "aws_security_group" "vpc_default":
│   11: data "aws_security_group" "vpc_default" {
│ 
╵
╷
│ Error: no matching SecurityGroup found
│ 
│   with module.metaflow.module.metaflow-metadata-service.data.aws_security_group.vpc_default,
│   on .terraform/modules/metaflow/modules/metadata-service/data.tf line 5, in data "aws_security_group" "vpc_default":
│    5: data "aws_security_group" "vpc_default" {
│ 
╵
I did setup the
infra
portion first.
1
a
Interesting, it looks like it can't find "default" security group for that VPC. I'm curious if you cam see it in AWS console?
a
@narrow-lion-2703 hey just reran it and checked that there isn't a security group created.
Also there are a bunch of warnings for undeclared variables and deprecated args.
I was digging into the
infra/terraform.tfstate
and under the
aws_vpc
there is an instance with a
default_security_group_id
set.
a
hmm are there any security groups for that VPC at all if you look in the console?
a
@average-beach-28850 yup the security group id was created.
a
🤔 depends on how deep you are in this thing, but i'd maybe try to terraform destroy it and try from scratch again, maybe using the example in the terraform repo instead
Another thing i can think of is that something is off with AWS region setting. Like if the region in your AWS config (
aws configure get region
) is different from what terraform template is using
a
@average-beach-28850 yeah I tried destroying and applying multiple times but no luck. I just checked and the region name in the AWS config and the
aws_region
in the tfvars file is the same.
Do you mean using this example? I will try out the CloudFormationTemplate as well just to be sure.
a
Yep that one. It is not using
infra
. Instead it is using a popular open source terraform module to create vpc
a
Ok I suppose I will need to spend a bit more time diving into why this is the case. Thankfully the CFN template works without any issues.