{"id":40061698,"url":"https://github.com/danielbmeireles/cloud-solutions-inc","last_synced_at":"2026-01-19T07:31:05.452Z","repository":{"id":319180970,"uuid":"1070391271","full_name":"danielbmeireles/cloud-solutions-inc","owner":"danielbmeireles","description":"Cloud Solutions Inc. is a fictional company. This repo defines the secure and scalable infrastructure for its applications.","archived":false,"fork":false,"pushed_at":"2025-10-26T13:40:31.000Z","size":244,"stargazers_count":0,"open_issues_count":2,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-26T15:07:05.227Z","etag":null,"topics":["argocd","aws","kubernetes","terraform"],"latest_commit_sha":null,"homepage":"","language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/danielbmeireles.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-05T20:34:47.000Z","updated_at":"2025-10-26T13:40:35.000Z","dependencies_parsed_at":"2025-10-18T10:41:57.008Z","dependency_job_id":null,"html_url":"https://github.com/danielbmeireles/cloud-solutions-inc","commit_stats":null,"previous_names":["danielbmeireles/cloud-solutions-inc"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/danielbmeireles/cloud-solutions-inc","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danielbmeireles%2Fcloud-solutions-inc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danielbmeireles%2Fcloud-solutions-inc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danielbmeireles%2Fcloud-solutions-inc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danielbmeireles%2Fcloud-solutions-inc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/danielbmeireles","download_url":"https://codeload.github.com/danielbmeireles/cloud-solutions-inc/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danielbmeireles%2Fcloud-solutions-inc/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28562993,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-19T03:31:16.861Z","status":"ssl_error","status_checked_at":"2026-01-19T03:31:15.069Z","response_time":67,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["argocd","aws","kubernetes","terraform"],"created_at":"2026-01-19T07:31:04.740Z","updated_at":"2026-01-19T07:31:05.446Z","avatar_url":"https://github.com/danielbmeireles.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cloud Solutions Inc. - Infrastructure as Code \u003c!-- omit in toc --\u003e\n\nProduction-ready AWS infrastructure for Cloud Solutions Inc., deployed using Terraform and Amazon EKS with a modern two-pipeline architecture.\n\n## Table of Contents \u003c!-- omit in toc --\u003e\n\n- [Quick Links](#quick-links)\n- [Features](#features)\n- [Architecture Overview](#architecture-overview)\n- [Quick Start](#quick-start)\n- [Security](#security)\n- [Modules](#modules)\n- [Outputs](#outputs)\n- [Cleanup](#cleanup)\n- [License](#license)\n\n\n## Quick Links\n\n- [ARCHITECTURE](docs/ARCHITECTURE.md) - Infrastructure components and design decisions\n- [ARGOCD](docs/ARGOCD.md) - ArgoCD deployment and access guide\n- [AWS LOAD BALANCER CONTROLLER](docs/ALB_CONTROLLER.md) - ALB/NLB controller documentation\n- [BOOTSTRAP](docs/BOOTSTRAP.md) - Remote state backend setup\n- [CICD](docs/CICD.md) - CI/CD pipeline documentation\n- [DISCLAIMER](docs/DISCLAIMER.md) - Important notes about the use of AI tools and development process\n- [EKS](docs/EKS.md) - EKS deployment, configuration, and operations\n- [EXAMPLES](docs/EXAMPLES.md) - Sample application deployment examples\n- [KUBERNETES](docs/KUBERNETES.md) - Kubernetes infrastructure deployment\n- [TERRAFORM](docs/TERRAFORM.md) - Terraform module and variable reference\n\n## Features\n\n- **Two-Pipeline Architecture**: Separate infrastructure and Kubernetes resource deployments\n- **Multi-environment**: Separate configurations for development, staging, and production\n- **EKS Cluster**: Managed Kubernetes 1.34 with auto-scaling node groups\n- **Multi-AZ**: High availability across 3 availability zones\n- **End-to-End Encryption**: KMS-encrypted secrets and EBS volumes, TLS in transit\n- **Network Isolation**: Private subnets for workloads, VPC Flow Logs\n- **Storage**: EFS for shared storage, EBS CSI driver\n- **Monitoring**: CloudWatch logs, metrics dashboard, SNS alerts\n- **CI/CD**: Automated GitHub Actions workflows with two-stage deployment\n- **GitOps**: ArgoCD for declarative application deployment\n- **IRSA**: IAM Roles for Service Accounts with OIDC provider\n- **Custom Helm Charts**: Professional wrapper charts for better maintainability\n\n## Architecture Overview\n\nThis project uses a **two-pipeline, two-state architecture** for better separation of concerns:\n\n```mermaid\nflowchart TB\n    subgraph P1[\"Pipeline 1: terraform-deploy\"]\n        direction TB\n        I1[\"Infrastructure Layer\"]\n        I2[\"- VPC, EKS, IAM\"]\n        I3[\"- KMS, EFS, ALB, CloudWatch\"]\n        I4[\"State: {env}/infra/tfstate\"]\n        I1 --\u003e I2 --\u003e I3 --\u003e I4\n    end\n\n    subgraph P2[\"Pipeline 2: kubernetes-deploy\"]\n        direction TB\n        K1[\"Kubernetes Resources Layer\"]\n        K2[\"- AWS Load Balancer Controller\"]\n        K3[\"- ArgoCD\"]\n        K4[\"State: {env}/kubernetes/tfstate\"]\n        K1 --\u003e K2 --\u003e K3 --\u003e K4\n    end\n\n    P1 --\u003e|triggers on success| P2\n```\n\n**Benefits:**\n- ✅ Separation of infrastructure and applications\n- ✅ Independent deployments and rollbacks\n- ✅ Reduced blast radius for changes\n- ✅ Follows HashiCorp best practices\n\nSee [ARCHITECTURE.md](docs/ARCHITECTURE.md) for detailed information.\n\n## Quick Start\n\n### 1. Clone Repository\n\n```bash\ngit clone https://github.com/your-username/cloud-solutions-inc.git\ncd cloud-solutions-inc\n```\n\n### 2. Create Terraform State Bucket\n\n```bash\n./scripts/bootstrap-terraform-backend.sh\n```\n\nOr with custom settings:\n\n```bash\nexport TF_STATE_BUCKET=\"my-terraform-state\"\nexport AWS_REGION=\"eu-west-1\"\n./scripts/bootstrap-terraform-backend.sh\n```\n\n### 3. Configure Variables\n\nCreate `environments/production/terraform.tfvars`:\n\n```hcl\naws_region         = \"eu-west-1\"\nenvironment        = \"production\"\nproject_name       = \"cloud-solutions\"\nvpc_cidr           = \"10.0.0.0/16\"\navailability_zones = [\"eu-west-1a\", \"eu-west-1b\", \"eu-west-1c\"]\n\n# EKS Configuration\nkubernetes_version  = \"1.34\"\nnode_instance_types = [\"t3.medium\"]\ncapacity_type       = \"ON_DEMAND\"\nnode_disk_size      = 20\n\n# Scaling\ndesired_size = 2\nmin_size     = 1\nmax_size     = 4\n\n# Optional: Email alerts\n# alarm_email = \"ops@cloudsolutions.com\"\n```\n\n### 4a. Manual Deploy - Infrastructure\n\n```bash\n# Deploy infrastructure layer\nterraform init -backend-config=\"environments/production/tfbackend.hcl\"\nterraform plan -var-file=\"environments/production/terraform.tfvars\"\nterraform apply -var-file=\"environments/production/terraform.tfvars\"\n```\n\n### 4b. Manual Deploy - Kubernetes Resources\n\n```bash\n# Deploy Kubernetes resources\ncd kubernetes\nterraform init -backend-config=\"environments/production/tfbackend.hcl\"\nterraform plan -var-file=\"environments/production/terraform.tfvars\"\nterraform apply -var-file=\"environments/production/terraform.tfvars\"\n```\n\n### 4c. Automated Deploy via CI/CD\n\nAutomated deployments via GitHub Actions on `main` branch push. The deployment happens in two stages:\n\n1. **terraform-deploy**: Deploys infrastructure (VPC, EKS, etc.)\n2. **kubernetes-deploy**: Deploys Kubernetes resources (triggered automatically on success)\n\nRequired secrets:\n- `AWS_ROLE_ARN`\n\nRequired variables:\n- `AWS_REGION`\n- `TF_VERSION`\n\nSee [CICD.md](docs/CICD.md) for detailed information.\n\n\n## Security\n\nAll data encrypted at rest (KMS for secrets/EBS) and in transit (TLS 1.2+). Key features:\n\n- Customer-managed KMS keys with automatic rotation\n- IMDSv2 enforced on all EC2 instances\n- Network isolation with security groups\n- VPC Flow Logs for auditing\n- IRSA for pod-level IAM permissions\n- Separate IAM roles for infrastructure and Kubernetes resources\n\nView encryption keys:\n```bash\nterraform output eks_kms_key_id\nterraform output ebs_kms_key_id\n```\n\nSee [ARCHITECTURE.md](docs/ARCHITECTURE.md#security-features) for comprehensive security documentation.\n\n## Modules\n\nThis project is organized into two main layers:\n\n### Infrastructure Layer (Root)\n- **kms**: Encryption key management\n- **vpc**: Network infrastructure\n- **eks**: EKS cluster and node groups\n- **alb**: Security groups for load balancers\n- **efs**: Shared file system\n- **cloudwatch**: Monitoring and logging\n\n### Kubernetes Layer (kubernetes/)\n- **Custom Charts**: Helm chart wrappers for better maintainability\n- **IAM Roles**: IRSA roles for Kubernetes service accounts\n- **ArgoCD**: GitOps deployment from shared module\n\nSee [TERRAFORM.md](docs/TERRAFORM.md) for detailed module documentation.\n\n## Outputs\n\n### Infrastructure Layer Outputs\n\n```bash\n# Cluster information\nterraform output eks_cluster_name\nterraform output eks_cluster_endpoint\nterraform output configure_kubectl\n\n# Security\nterraform output eks_kms_key_id\nterraform output ebs_kms_key_id\n\n# OIDC for IRSA\nterraform output eks_oidc_provider\nterraform output eks_oidc_provider_arn\n\n# Sensitive outputs\nterraform output -raw eks_cluster_arn\n```\n\n### Kubernetes Layer Outputs\n\n```bash\ncd kubernetes\n\n# ArgoCD information\nterraform output argocd_namespace\nterraform output argocd_server_url\n\n# Load Balancer Controller\nterraform output aws_load_balancer_controller_role_arn\n```\n\n## Cleanup\n\n**Important**: Delete resources in reverse order to avoid orphaned AWS resources.\n\n```bash\n# 1. Delete all Kubernetes-created AWS resources (while controllers are still running)\nkubectl delete ingress --all --all-namespaces\nkubectl delete svc --all --all-namespaces\nkubectl delete pvc --all --all-namespaces\n\n# 2. Delete Kubernetes resources (removes controllers and ArgoCD)\ncd kubernetes\nterraform destroy\n\n# 3. Delete infrastructure (removes EKS cluster and VPC)\ncd ..\nterraform destroy\n```\n\n## License\n\nThis project is licensed under the [MIT License](LICENSE).\n\n---\n\n**Built with ❤️ for Cloud Solutions Inc.**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanielbmeireles%2Fcloud-solutions-inc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdanielbmeireles%2Fcloud-solutions-inc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanielbmeireles%2Fcloud-solutions-inc/lists"}