{"id":27697910,"url":"https://github.com/rishabkumar7/uptime-kuma-gcp-vm","last_synced_at":"2026-01-23T12:18:54.928Z","repository":{"id":269267156,"uuid":"904331816","full_name":"rishabkumar7/uptime-kuma-gcp-vm","owner":"rishabkumar7","description":"Terraform code to host Uptime Kuma hosted on GCP VM.","archived":false,"fork":false,"pushed_at":"2024-12-17T04:12:40.000Z","size":5,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-23T11:11:47.096Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/rishabkumar7.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}},"created_at":"2024-12-16T17:22:40.000Z","updated_at":"2024-12-17T16:21:55.000Z","dependencies_parsed_at":"2024-12-22T09:57:06.088Z","dependency_job_id":"13da497d-9178-45b5-9d13-49c8c6857df9","html_url":"https://github.com/rishabkumar7/uptime-kuma-gcp-vm","commit_stats":null,"previous_names":["rishabkumar7/uptime-kuma-gcp-vm"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rishabkumar7%2Fuptime-kuma-gcp-vm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rishabkumar7%2Fuptime-kuma-gcp-vm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rishabkumar7%2Fuptime-kuma-gcp-vm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rishabkumar7%2Fuptime-kuma-gcp-vm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rishabkumar7","download_url":"https://codeload.github.com/rishabkumar7/uptime-kuma-gcp-vm/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250852105,"owners_count":21497807,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2025-04-25T16:26:26.331Z","updated_at":"2026-01-23T12:18:49.882Z","avatar_url":"https://github.com/rishabkumar7.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Uptime Kuma on Google Cloud Platform\n\nThis Terraform configuration deploys Uptime Kuma, an open-source monitoring tool, on GCP VM using Container-Optimized OS and Docker.\n\n## Features\n\n- Runs on GCP's free tier eligible VM (e2-micro)\n- Persistent storage for monitoring data\n- Automatic container deployment\n- Uses Container-Optimized OS for better security and performance\n\n## Prerequisites\n\n- Google Cloud Platform account with billing enabled\n- Terraform installed (version \u003e= 1.0.0)\n- Google Cloud CLI installed\n- A GCP project with required APIs enabled:\n  - Compute Engine API\n  - Cloud Resource Manager API\n\n## Directory Structure\n\n```\nuptime-kuma-gcp-vm/\n├── main.tf          # Main Terraform configuration\n├── variables.tf     # Declaring variables for terraform configuration\n├── terraform.tfvars # Variables configuration (create this)\n└── README.md        # This file\n```\n\n## Quick Start\n\n1. Clone this repository:\n\n```bash\ngit clone https://github.com/rishabkumar7/uptime-kuma-gcp-vm\ncd uptime-kuma-gcp-vm\n```\n\n2. Create a `terraform.tfvars` file:\n\n```hcl\nproject_id = \"your-project-id\"\n```\n\n3. Initialize and apply:\n\n```bash\nterraform init\nterraform apply\n```\n\n4. Access Uptime Kuma at\n\n```\nhttp://\u003cinstance-ip\u003e:3001\n```\n\nThe IP address will be shown in Terraform's output.\n\n## Configuration Options\n\nEdit `terraform.tfvars` to customize your deployment:\n\n```hcl\nproject_id = \"your-project-id\"\nregion = \"us-central1\"      # Default: us-central1\nzone = \"us-central1-a\"      # Default: us-central1-a\nmachine_type = \"e2-micro\"   # Default: e2-micro\ndisk_size = 20             # Default: 20 GB\nboot_disk_size = 10        # Default: 10 GB\n```\n\n## Maintenance\n\n### Updating Uptime Kuma\n\nTo update to a new version, modify the container image tag in `main.tf`:\n\n```hcl\nimage = \"registry.hub.docker.com/louislam/uptime-kuma:new-version\"\n```\n\nThen run:\n\n```bash\nterraform apply\n```\n\n### Backup\n\nThe monitoring data is stored on a persistent disk. To create a backup:\n\n1. Stop the VM in GCP Console\n2. Create a snapshot of the `kuma-disk`\n3. Restart the VM\n\n### Clean Up\n\nTo remove all resources:\n\n```bash\nterraform destroy\n```\n\n⚠️ Warning: This will delete all resources including monitoring data!\n\n## Troubleshooting\n\n### Can't Access Uptime Kuma\n\n1. Wait 2-3 minutes after deployment for container initialization\n2. Verify VM is running:\n\n```bash\ngcloud compute instances describe uptime-kuma-vm\n```\n\n3. Check container logs:\n\n```bash\ngcloud compute ssh uptime-kuma-vm --command=\"docker ps \u0026\u0026 docker logs \\$(docker ps -q)\"\n```\n\n### Common Issues\n\n- **Terraform Provider Error**: Make sure you've enabled the necessary APIs\n- **Container Not Starting**: Check logs using the command above\n- **Disk Not Mounting**: Check startup script logs in GCP Console\n\n## Security Notes\n\n- The deployment opens port 3001 to all IPs (0.0.0.0/0)\n- Consider limiting `source_ranges` in the firewall rule\n- Container runs as non-root user\n- Uses Container-Optimized OS for enhanced security\n\n## Contributing\n\nFeel free to submit issues and pull requests!\n\n## License\n\n[MIT License](LICENSE)\n\n## Author\n\n[Rishab Kumar](https://rishabkumar.com)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frishabkumar7%2Fuptime-kuma-gcp-vm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frishabkumar7%2Fuptime-kuma-gcp-vm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frishabkumar7%2Fuptime-kuma-gcp-vm/lists"}