{"id":15680877,"url":"https://github.com/cirocosta/auto53","last_synced_at":"2025-05-07T11:18:57.011Z","repository":{"id":73883699,"uuid":"96626283","full_name":"cirocosta/auto53","owner":"cirocosta","description":"Automatic Route53 updates based on EC2 Autoscaling state changes","archived":false,"fork":false,"pushed_at":"2017-12-10T18:01:08.000Z","size":8732,"stargazers_count":10,"open_issues_count":5,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-07T11:18:18.690Z","etag":null,"topics":["autoscaling","aws","ec2","golang","route53"],"latest_commit_sha":null,"homepage":"","language":"Go","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/cirocosta.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}},"created_at":"2017-07-08T15:10:39.000Z","updated_at":"2025-02-11T15:49:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"3a37f7f2-831a-4137-8ecd-5cc03022e96e","html_url":"https://github.com/cirocosta/auto53","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cirocosta%2Fauto53","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cirocosta%2Fauto53/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cirocosta%2Fauto53/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cirocosta%2Fauto53/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cirocosta","download_url":"https://codeload.github.com/cirocosta/auto53/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252865594,"owners_count":21816310,"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":["autoscaling","aws","ec2","golang","route53"],"created_at":"2024-10-03T16:45:31.098Z","updated_at":"2025-05-07T11:18:56.988Z","avatar_url":"https://github.com/cirocosta.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003eauto53 📂  \u003c/h1\u003e\n\n\u003ch5 align=\"center\"\u003eThe missing link between AWS AutoScaling Groups and Route53\u003c/h5\u003e\n\n\u003cbr/\u003e\n\n[![Build Status](https://travis-ci.com/cirocosta/auto53.svg?token=ixZ9XiEPW4YH62ixq7Av\u0026branch=master)](https://travis-ci.com/cirocosta/auto53)\n\n\n### Overview\n\n`auto53` solves the issue of keeping a route53 zone up to date with the changes that an autoscaling group might face. \n\nFor instance, consider the following state in EC2:\n\n```yaml\n# internal state retrieved from the \n# inspection of EC2\nautoscaling_groups:\n  - name: asg1\n    instances:\n      - id: 'i-0123'\n        private_ip: '10.0.0.2'\n      - id: 'i-0321'\n        private_ip: '10.0.0.3' \n```\n\nand also the following formatting configuration:\n\n```yaml\n# for each zone we can tie several\n# autoscaling groups that present\n# an automatic record creation rule.\n--- \n- AutoScalingGroup: 'asg1'\n  Zone': \n    ID: 'zone123'\n    Name: 'ciro-test'\n  Record: 'asg1-machines'\n\n- AutoScalingGroup: 'asg1'\n  Zone': \n    ID: 'zone123'\n    Name: 'ciro-test'\n  Record: '{{ .Id }}-machine'\n```\n\nwith that we'd end up with the following records:\n\n```yaml\nasg1-machines.ciro-test:\n  - 10.0.0.2\n  - 10.0.0.3\n\ni-0123-machine.ciro-test:\n  - 10.0.0.2\n\ni-0321-machine.ciro-test:\n  - 10.0.0.3\n```\n\nNow we could consider the situation where `asg1` scales out to `3` instances while at the same time having the death of `i-0321`:\n\n\n```diff\n autoscaling_groups:\n   asg1:\n     machines:\n       - id: 'i-0123'\n         private_ip: '10.0.0.2'\n-      - id: 'i-0321'\n-        private_ip: '10.0.0.3' \n+      - id: 'i-0444'\n+        private_ip: '10.0.0.4' \n+      - id: 'i-0555'\n+        private_ip: '10.0.0.5' \n```\n\nThat would mean that `auto53` would notice the change in the desired state and then update `route53` accordingly:\n\n\n\n```yaml\nasg1-machines.ciro-test:\n  - 10.0.0.2\n  - 10.0.0.4\n  - 10.0.0.5\n\ni-0123-machine.ciro-test:\n  - 10.0.0.2\n\ni-0444-machine.ciro-test:\n  - 10.0.0.4\n\ni-0555-machine.ciro-test:\n  - 10.0.0.5\n```\n\n### Usage\n\n`auto53` aims at being a single binary that is capable of running in 2 modes:\n\n- server mode: sits in an instance querying route53 state from time to time as well as being (optionally) notified by SNS in case of any changes in an autoscaling group;\n- single execution mode: runs once whenever the binary is fired - suitable for executions in the context of a one-off lambda function.\n\nIn either case, the necessary user permissions are needed:\n\n- EC2 Describe Instances\n- Route53 - ListResourceRecordSets, ChangeResourceRecordSets\n\nThe AWS credentials are accessed via the default behavior of AWS CLI (either environment variables or config file under `~/.aws`).\n\n```\nUsage: auto53 [opts ...]\n\nOptions:\n  --config CONFIG [default: ./auto53.yaml]\n  --debug                activates debug-level logging\n  --dry                  run without performing modifications\n  --interval INTERVAL [default: 2m0s]\n  --listen\n  --once                 run one time and exit\n  --port PORT [default: 8080]\n  --help, -h             display this help and exit\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcirocosta%2Fauto53","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcirocosta%2Fauto53","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcirocosta%2Fauto53/lists"}