Dear Experts,
I followed the provided guide to download the module, but unfortunately, I encountered some issues. I added the module in the cdktf.json
file and then executed cdktf gen
. As a result, the vpc.ts
file was successfully generated. However, when I attempted to deploy it, I encountered an error message:
ubuntu@ip-172-31-16-130:~/eks-app$ cdktf deploy
eks-app Running apply in Terraform Cloud. Output will stream here. Pressing Ctrl-C
will cancel the remote apply if it's still pending. If the apply started it
will stop streaming the logs, but will not stop the apply running remotely.
Preparing the remote apply...
eks-app ╷
│ Error: error loading config with snapshot: cdk.tf.json:25,12-13: Module not installed; This module is not yet installed. Run "terraform init" to install all modules required by this configuration.
│
│
╵
0 Stacks deploying 1 Stack done 0 Stacks waiting
Invoking Terraform CLI failed with exit code 1
ubuntu@ip-172-31-16-130:~/eks-app$ rm .gen/ -rf
This is my cdktf.json
:
{
"language": "typescript",
"app": "npx ts-node main.ts",
"projectId": "36c31cb2-be41-4217-890f-02eea2057b10",
"sendCrashReports": "false",
"terraformProviders": [],
"terraformModules": [
{
"name": "vpc",
"source": "terraform-aws-modules/vpc/aws",
"version": "4.0.1"
}
],
"context": {
"excludeStackIdFromLogicalIds": "true",
"allowSepCharsInLogicalIds": "true"
}
}
I have the latest Terraform CDK version (0.16.1)
What could be the issue?
Thanks
Fatos