Skip to content

Commit 34c33e3

Browse files
authored
Update README.md
1 parent 9aa6d5e commit 34c33e3

File tree

1 file changed

+106
-24
lines changed

1 file changed

+106
-24
lines changed

README.md

Lines changed: 106 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,5 @@
11
# Comet Infrastructure Deployment: Terraform on AWS
2-
Terraform module for deploying infrastructure components to run CometML
3-
4-
### Modules
5-
**Root Configuration**
6-
7-
**comet_ec2**
8-
9-
**comet_ec2_alb**
10-
11-
**comet_eks**
12-
13-
**comet_elasticache**
14-
15-
**comet_rds**
16-
17-
**comet_s3**
2+
Terraform module for deploying infrastructure components to run CometML.
183

194
### Deployment
205
**Prerequisites:**
@@ -25,11 +10,108 @@ Terraform module for deploying infrastructure components to run CometML
2510
- [Terraform](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/install-cli) installed
2611

2712
**Infrastructure Deployment:**
28-
- Clone the repository to your local machine: `git clone https://github.com/comet-ml/dply-terraform-aws.git`
29-
- Move into the deployment directory: `cd dply-terraform-aws/comet-infrastructure`
30-
- Initialize the directory: `terraform init`
31-
- Within terraform.tfvars, set your module toggles to enable the desired infrastructure components and set any required environment variables
32-
- Provision the resources: `terraform apply`
33-
34-
### Cleanup
35-
- `terraform destroy`
13+
- Follow the steps below to deploy directly from this repository.
14+
- Clone the repository to your local machine: `git clone https://github.com/comet-ml/dply-terraform-aws.git`
15+
- Move into the deployment directory: `cd dply-terraform-aws/comet-infrastructure`
16+
- Initialize the directory: `terraform init`
17+
- Within terraform.tfvars, set your module toggles to enable the desired infrastructure components and set any related inputs
18+
- Provision the resources: `terraform apply`
19+
20+
## Requirements
21+
22+
| Name | Version |
23+
|------|---------|
24+
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.0 |
25+
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | ~> 5.1 |
26+
| <a name="requirement_helm"></a> [helm](#requirement\_helm) | ~>2.10 |
27+
| <a name="requirement_kubernetes"></a> [kubernetes](#requirement\_kubernetes) | ~> 2.21 |
28+
29+
## Providers
30+
31+
| Name | Version |
32+
|------|---------|
33+
| <a name="provider_aws"></a> [aws](#provider\_aws) | 5.8.0 |
34+
35+
## Modules
36+
37+
| Name | Source | Version |
38+
|------|--------|---------|
39+
| <a name="module_comet_ec2"></a> [comet\_ec2](#module\_comet\_ec2) | ./modules/comet_ec2 | n/a |
40+
| <a name="module_comet_ec2_alb"></a> [comet\_ec2\_alb](#module\_comet\_ec2\_alb) | ./modules/comet_ec2_alb | n/a |
41+
| <a name="module_comet_eks"></a> [comet\_eks](#module\_comet\_eks) | ./modules/comet_eks | n/a |
42+
| <a name="module_comet_elasticache"></a> [comet\_elasticache](#module\_comet\_elasticache) | ./modules/comet_elasticache | n/a |
43+
| <a name="module_comet_rds"></a> [comet\_rds](#module\_comet\_rds) | ./modules/comet_rds | n/a |
44+
| <a name="module_comet_s3"></a> [comet\_s3](#module\_comet\_s3) | ./modules/comet_s3 | n/a |
45+
| <a name="module_comet_vpc"></a> [comet\_vpc](#module\_comet\_vpc) | ./modules/comet_vpc | n/a |
46+
47+
## Resources
48+
49+
| Name | Type |
50+
|------|------|
51+
| [aws_eks_cluster_auth.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/eks_cluster_auth) | data source |
52+
53+
## Inputs
54+
55+
| Name | Description | Type | Default | Required |
56+
|------|-------------|------|---------|:--------:|
57+
| <a name="input_availability_zones"></a> [availability\_zones](#input\_availability\_zones) | List of availability zones from region | `list(string)` | `null` | no |
58+
| <a name="input_comet_ec2_ami_type"></a> [comet\_ec2\_ami\_type](#input\_comet\_ec2\_ami\_type) | Operating system type for the EC2 instance AMI | `string` | `"ubuntu22"` | no |
59+
| <a name="input_comet_ec2_instance_count"></a> [comet\_ec2\_instance\_count](#input\_comet\_ec2\_instance\_count) | Number of EC2 instances to provision | `number` | `1` | no |
60+
| <a name="input_comet_ec2_instance_type"></a> [comet\_ec2\_instance\_type](#input\_comet\_ec2\_instance\_type) | Instance type for the EC2 instance | `string` | `"m5.4xlarge"` | no |
61+
| <a name="input_comet_ec2_key"></a> [comet\_ec2\_key](#input\_comet\_ec2\_key) | Name of the SSH key to configure on the EC2 instance | `string` | `null` | no |
62+
| <a name="input_comet_ec2_volume_size"></a> [comet\_ec2\_volume\_size](#input\_comet\_ec2\_volume\_size) | Size, in gibibytes (GiB), for the EC2 instance root volume | `number` | `1024` | no |
63+
| <a name="input_comet_ec2_volume_type"></a> [comet\_ec2\_volume\_type](#input\_comet\_ec2\_volume\_type) | EBS volume type for the EC2 instance root volume | `string` | `"gp2"` | no |
64+
| <a name="input_comet_private_subnets"></a> [comet\_private\_subnets](#input\_comet\_private\_subnets) | List of private subnets IDs from existing VPC to provision resources in | `list(string)` | `null` | no |
65+
| <a name="input_comet_public_subnets"></a> [comet\_public\_subnets](#input\_comet\_public\_subnets) | List of public subnets IDs from existing VPC to provision resources in | `list(string)` | `null` | no |
66+
| <a name="input_comet_vpc_id"></a> [comet\_vpc\_id](#input\_comet\_vpc\_id) | ID of an existing VPC to provision resources in | `string` | `null` | no |
67+
| <a name="input_eks_aws_cloudwatch_metrics"></a> [eks\_aws\_cloudwatch\_metrics](#input\_eks\_aws\_cloudwatch\_metrics) | Enables AWS Cloudwatch Metrics in the EKS cluster | `bool` | `true` | no |
68+
| <a name="input_eks_aws_load_balancer_controller"></a> [eks\_aws\_load\_balancer\_controller](#input\_eks\_aws\_load\_balancer\_controller) | Enables the AWS Load Balancer Controller in the EKS cluster | `bool` | `true` | no |
69+
| <a name="input_eks_cert_manager"></a> [eks\_cert\_manager](#input\_eks\_cert\_manager) | Enables cert-manager in the EKS cluster | `bool` | `true` | no |
70+
| <a name="input_eks_cluster_name"></a> [eks\_cluster\_name](#input\_eks\_cluster\_name) | Name for EKS cluster | `string` | `"comet-eks"` | no |
71+
| <a name="input_eks_cluster_version"></a> [eks\_cluster\_version](#input\_eks\_cluster\_version) | Kubernetes version of the EKS cluster | `string` | `"1.26"` | no |
72+
| <a name="input_eks_external_dns"></a> [eks\_external\_dns](#input\_eks\_external\_dns) | Enables ExternalDNS in the EKS cluster | `bool` | `true` | no |
73+
| <a name="input_eks_mng_ami_type"></a> [eks\_mng\_ami\_type](#input\_eks\_mng\_ami\_type) | AMI family to use for the EKS nodes | `string` | `"AL2_x86_64"` | no |
74+
| <a name="input_eks_mng_desired_size"></a> [eks\_mng\_desired\_size](#input\_eks\_mng\_desired\_size) | Desired number of nodes in EKS cluster | `number` | `3` | no |
75+
| <a name="input_eks_mng_max_size"></a> [eks\_mng\_max\_size](#input\_eks\_mng\_max\_size) | Maximum number of nodes in EKS cluster | `number` | `6` | no |
76+
| <a name="input_eks_mng_name"></a> [eks\_mng\_name](#input\_eks\_mng\_name) | Name for the EKS managed nodegroup | `string` | `"mng"` | no |
77+
| <a name="input_eks_node_types"></a> [eks\_node\_types](#input\_eks\_node\_types) | Node instance types for EKS managed node group | `list(string)` | <pre>[<br> "m5.4xlarge"<br>]</pre> | no |
78+
| <a name="input_elasticache_allow_from_sg"></a> [elasticache\_allow\_from\_sg](#input\_elasticache\_allow\_from\_sg) | Security group from which to allow connections to ElastiCache, to use when provisioning with existing compute | `string` | `null` | no |
79+
| <a name="input_elasticache_engine"></a> [elasticache\_engine](#input\_elasticache\_engine) | Engine type for ElastiCache cluster | `string` | `"redis"` | no |
80+
| <a name="input_elasticache_engine_version"></a> [elasticache\_engine\_version](#input\_elasticache\_engine\_version) | Version number for ElastiCache engine | `string` | `"5.0.6"` | no |
81+
| <a name="input_elasticache_instance_type"></a> [elasticache\_instance\_type](#input\_elasticache\_instance\_type) | ElastiCache instance type | `string` | `"cache.r4.xlarge"` | no |
82+
| <a name="input_elasticache_num_cache_nodes"></a> [elasticache\_num\_cache\_nodes](#input\_elasticache\_num\_cache\_nodes) | Number of nodes in the ElastiCache cluster | `number` | `1` | no |
83+
| <a name="input_elasticache_param_group_name"></a> [elasticache\_param\_group\_name](#input\_elasticache\_param\_group\_name) | Name for the ElastiCache cluster parameter group | `string` | `"default.redis5.0"` | no |
84+
| <a name="input_enable_ec2"></a> [enable\_ec2](#input\_enable\_ec2) | Toggles the comet\_ec2 module, to provision EC2 resources for running Comet | `bool` | n/a | yes |
85+
| <a name="input_enable_ec2_alb"></a> [enable\_ec2\_alb](#input\_enable\_ec2\_alb) | Toggles the comet\_ec2\_alb module, to provision an ALB in front of the EC2 instance | `bool` | n/a | yes |
86+
| <a name="input_enable_eks"></a> [enable\_eks](#input\_enable\_eks) | Toggles the comet\_eks module, to provision EKS resources for running Comet | `bool` | n/a | yes |
87+
| <a name="input_enable_elasticache"></a> [enable\_elasticache](#input\_enable\_elasticache) | Toggles the comet\_elasticache module for provisioning Comet Redis on elasticache | `bool` | n/a | yes |
88+
| <a name="input_enable_rds"></a> [enable\_rds](#input\_enable\_rds) | Toggles the comet\_rds module for provisioning Comet RDS database | `bool` | n/a | yes |
89+
| <a name="input_enable_s3"></a> [enable\_s3](#input\_enable\_s3) | Toggles the comet\_s3 module for provisioning Comet S3 bucket | `bool` | n/a | yes |
90+
| <a name="input_enable_vpc"></a> [enable\_vpc](#input\_enable\_vpc) | Toggles the comet\_vpc module, to provision a new VPC for hosting the Comet resources | `bool` | n/a | yes |
91+
| <a name="input_environment"></a> [environment](#input\_environment) | Deployment environment, i.e. dev/stage/prod, etc | `string` | `"dev"` | no |
92+
| <a name="input_rds_allow_from_sg"></a> [rds\_allow\_from\_sg](#input\_rds\_allow\_from\_sg) | Security group from which to allow connections to RDS, to use when provisioning with existing compute | `string` | `null` | no |
93+
| <a name="input_rds_backup_retention_period"></a> [rds\_backup\_retention\_period](#input\_rds\_backup\_retention\_period) | Days specified for RDS snapshotretention period | `number` | `7` | no |
94+
| <a name="input_rds_database_name"></a> [rds\_database\_name](#input\_rds\_database\_name) | Name for the application database in RDS | `string` | `"logger"` | no |
95+
| <a name="input_rds_engine"></a> [rds\_engine](#input\_rds\_engine) | Engine type for RDS database | `string` | `"aurora-mysql"` | no |
96+
| <a name="input_rds_engine_version"></a> [rds\_engine\_version](#input\_rds\_engine\_version) | Engine version number for RDS database | `string` | `"5.7"` | no |
97+
| <a name="input_rds_iam_db_auth"></a> [rds\_iam\_db\_auth](#input\_rds\_iam\_db\_auth) | Enables IAM auth for the database in RDS | `bool` | `true` | no |
98+
| <a name="input_rds_instance_count"></a> [rds\_instance\_count](#input\_rds\_instance\_count) | Number of RDS instances in the database cluster | `number` | `2` | no |
99+
| <a name="input_rds_instance_type"></a> [rds\_instance\_type](#input\_rds\_instance\_type) | Instance type for RDS database | `string` | `"db.r5.xlarge"` | no |
100+
| <a name="input_rds_preferred_backup_window"></a> [rds\_preferred\_backup\_window](#input\_rds\_preferred\_backup\_window) | Backup window for RDS | `string` | `"07:00-09:00"` | no |
101+
| <a name="input_rds_root_password"></a> [rds\_root\_password](#input\_rds\_root\_password) | Root password for RDS database | `string` | n/a | yes |
102+
| <a name="input_rds_storage_encrypted"></a> [rds\_storage\_encrypted](#input\_rds\_storage\_encrypted) | Enables encryption for RDS storage | `bool` | `true` | no |
103+
| <a name="input_region"></a> [region](#input\_region) | AWS region to provision resources in | `string` | n/a | yes |
104+
| <a name="input_s3_bucket_name"></a> [s3\_bucket\_name](#input\_s3\_bucket\_name) | Name for S3 bucket | `string` | n/a | yes |
105+
| <a name="input_single_nat_gateway"></a> [single\_nat\_gateway](#input\_single\_nat\_gateway) | Controls whether single NAT gateway used for all public subnets | `bool` | `true` | no |
106+
| <a name="input_ssl_certificate_arn"></a> [ssl\_certificate\_arn](#input\_ssl\_certificate\_arn) | ARN of the ACM certificate to use for the ALB | `string` | `null` | no |
107+
108+
## Outputs
109+
110+
| Name | Description |
111+
|------|-------------|
112+
| <a name="output_comet_alb_dns_name"></a> [comet\_alb\_dns\_name](#output\_comet\_alb\_dns\_name) | DNS name of the ALB fronting the Comet EC2 instance |
113+
| <a name="output_comet_ec2_instance"></a> [comet\_ec2\_instance](#output\_comet\_ec2\_instance) | ID of the Comet EC2 instance |
114+
| <a name="output_comet_ec2_public_ip"></a> [comet\_ec2\_public\_ip](#output\_comet\_ec2\_public\_ip) | EIP associated with the Comet EC2 instance |
115+
| <a name="output_configure_kubectl"></a> [configure\_kubectl](#output\_configure\_kubectl) | Configure kubectl: run the following command to update your kubeconfig with the newly provisioned cluster. |
116+
| <a name="output_mysql_host"></a> [mysql\_host](#output\_mysql\_host) | Endpoint for the RDS instance |
117+
| <a name="output_region"></a> [region](#output\_region) | Region resources are provisioned in |

0 commit comments

Comments
 (0)