{"id":49941459,"url":"https://github.com/budd9442/canvas","last_synced_at":"2026-05-17T11:35:34.893Z","repository":{"id":350412277,"uuid":"1122753960","full_name":"budd9442/canvas","owner":"budd9442","description":"Distributed Collaborative Paint Canvas","archived":false,"fork":false,"pushed_at":"2026-04-10T08:13:42.000Z","size":252,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-04-10T09:29:38.368Z","etag":null,"topics":["cloud-computing","distributed-systems","docker","k8s-api","kubernetes","prometheus-grafana"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/budd9442.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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-12-25T12:38:30.000Z","updated_at":"2026-04-10T08:13:53.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/budd9442/canvas","commit_stats":null,"previous_names":["budd9442/canvas"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/budd9442/canvas","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/budd9442%2Fcanvas","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/budd9442%2Fcanvas/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/budd9442%2Fcanvas/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/budd9442%2Fcanvas/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/budd9442","download_url":"https://codeload.github.com/budd9442/canvas/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/budd9442%2Fcanvas/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33136912,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-17T09:28:26.183Z","status":"ssl_error","status_checked_at":"2026-05-17T09:27:52.702Z","response_time":107,"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":["cloud-computing","distributed-systems","docker","k8s-api","kubernetes","prometheus-grafana"],"created_at":"2026-05-17T11:35:33.140Z","updated_at":"2026-05-17T11:35:34.887Z","avatar_url":"https://github.com/budd9442.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Distributed Collaborative Paint Canvas 🎨\n\n![License](https://img.shields.io/badge/license-MIT-blue.svg)\n![AWS](https://img.shields.io/badge/AWS-EKS_1.30-orange.svg)\n![Terraform](https://img.shields.io/badge/IaC-Terraform-blueviolet.svg)\n![Status](https://img.shields.io/badge/status-production_ready-green.svg)\n\nA real-time, distributed collaborative drawing application designed to demonstrate the principles of **Distributed Systems**, **High Availability**, and **GitOps-driven Cloud Orchestration**.\n\n---\n\n## 🏗 Choose Your Architecture\n\nThis project evolved from a single-node VPS deployment into a professional, multi-AZ AWS cloud infrastructure. You can deploy it in two ways:\n\n### 1. **AWS Production Deployment **\n*   **Infrastructure**: AWS EKS (Kubernetes), RDS (PostgreSQL), ElastiCache (Redis), Secrets Manager, ALB.\n*   **Logic**: Fully automated via Terraform (IaC) and GitHub Actions (CI/CD).\n\n### 2. **Local / VPS Deployment **\n*   **Infrastructure**: Lightweight `k3s` cluster, Docker Compose, or manual Node.js.\n*   **Logic**: Standard `kubectl apply` manifests.\n*   **Location**: Legacy manifests are preserved in the [`k83-vps/`](./k83-vps/) directory.\n\n---\n\n## 🚀 AWS Enterprise Deployment (EKS)\n\n### Prerequisites\n*   AWS CLI configured with Admin permissions.\n*   Terraform 1.5+\n*   kubectl \u0026 Helm\n\n### Step 1: Bootstrap the State\nBefore deploying the main resources, initialize the remote S3 backend and DynamoDB state lock:\n```bash\ncd terraform/bootstrap\nterraform init \u0026\u0026 terraform apply\n```\n\n### Step 2: Provision Infrastructure\nUpdate `terraform/main/provider.tf` with the S3 bucket name from the bootstrap step, then:\n```bash\ncd terraform/main\nterraform init\nterraform apply\n```\n*This will provision a custom VPC, EKS Cluster, RDS Postgres, and ElastiCache Redis (~15-20 mins).*\n\n### Step 3: GitOps Rollout\n1.  Add your `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` to GitHub Repository Secrets.\n2.  Push a change to the `master` branch.\n3.  The [Deployment Workflow](./.github/workflows/deploy.yaml) will automatically build the images, push to ECR, and deploy to EKS.\n\n---\n\n## 🐧 Legacy VPS Deployment (k3s)\n\nIf you are deploying to a standard Linux VPS using `k3s`:\n\n1.  **Ensure k3s is installed**: `curl -sfL https://get.k3s.io | sh -`\n2.  **Deploy Manifests**:\n    ```bash\n    kubectl apply -f k83-vps/\n    ```\n3.  **Config**: Update the `Ingress` in `k83-vps/ingress.yaml` with your VPS IP or public domain.\n\n---\n\n## 🛠 Tech Stack\n\n| Component | AWS Technology | VPS/Local Technology |\n|-----------|----------------|----------------------|\n| **Kubernetes** | Amazon EKS (Managed) | k3s (Lightweight) |\n| **Database** | Amazon RDS (PostgreSQL) | In-cluster Postgres Pod |\n| **Cache** | Amazon ElastiCache (Redis) | In-cluster Redis Pod |\n| **Ingress** | AWS Load Balancer (ALB) | Traefik / Nginx |\n| **Secrets** | AWS Secrets Manager | K8s Secrets (Base64) |\n| **Registry** | Amazon ECR | Docker Hub |\n| **IaC** | Terraform | Manual Manifests |\n\n---\n\n## 📉 Stress Testing \u0026 HPA\nThe system is built to breathe. We’ve included a \"Bot Army\" tester to verify Horizontal Pod Autoscaling (HPA).\n\n1.  **Install Tester**:\n    ```bash\n    cd tester\n    npm install\n    ```\n2.  **Run \"Starry Night\" Attack**:\n    ```bash\n    # Simulates 250 concurrent bots drawing a Van Gogh painting\n    CONCURRENCY=250 INTERVAL=10 node flood.js\n    ```\n3.  **Monitor Scaling**:\n    ```bash\n    kubectl get hpa paint-backend -w\n    ```\n    \n---\n\n## 📄 License\nThis project is licensed under the MIT License - see the [LICENSE](./LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbudd9442%2Fcanvas","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbudd9442%2Fcanvas","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbudd9442%2Fcanvas/lists"}