{"id":18538715,"url":"https://github.com/hatena/swiro","last_synced_at":"2025-04-09T17:37:38.747Z","repository":{"id":44439571,"uuid":"76931533","full_name":"hatena/swiro","owner":"hatena","description":"swiro - A switching route tool for AWS","archived":false,"fork":false,"pushed_at":"2022-07-12T02:29:30.000Z","size":50,"stargazers_count":11,"open_issues_count":0,"forks_count":0,"subscribers_count":13,"default_branch":"master","last_synced_at":"2025-03-24T09:46:53.123Z","etag":null,"topics":["aws","go","golang"],"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/hatena.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-12-20T06:55:03.000Z","updated_at":"2022-07-12T02:29:31.000Z","dependencies_parsed_at":"2022-07-15T17:00:58.275Z","dependency_job_id":null,"html_url":"https://github.com/hatena/swiro","commit_stats":null,"previous_names":["taku-k/swiro"],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hatena%2Fswiro","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hatena%2Fswiro/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hatena%2Fswiro/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hatena%2Fswiro/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hatena","download_url":"https://codeload.github.com/hatena/swiro/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248078461,"owners_count":21044109,"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":["aws","go","golang"],"created_at":"2024-11-06T19:44:46.989Z","updated_at":"2025-04-09T17:37:38.487Z","avatar_url":"https://github.com/hatena.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# swiro\n\nswiro is a switching route tool for AWS to realize VIP (Virtual IP) with Routing-Based High Availability pattern.\n\nThis pattern is possible to perform failover (switching of the connection destination) of the EC2 redundant across the subnet (AZ).\n\n\n## Usage\n\n* List routes\n\n```\n$ swiro list\n```\n\n* Switching routes\n\n```\n$ swiro switch -r rtb-xxxxxx -v 10.0.0.1 -I i-xxxxxx\n```\n\n\n## Example\n\n### List routes\n\n```\n$ swiro list\n===\u003e Route Table: route_table_1 (rtb-xxxxxx1)\n---\u003e Virtual IP:  10.0.0.1/32 =======\u003e src_instance_1 (i-yyyyyy1)\n---\u003e Virtual IP:  10.0.0.2/32 =======\u003e src_instance_2 (i-yyyyyy2)\n===\u003e Route Table: route_table_2 (rtb-xxxxxx2)\n---\u003e Virtual IP:  10.0.0.3/32 =======\u003e src_instance_3 (i-yyyyyy3)\n```\n\n### Switching routes\n\nIn most cases you can switch the routing with the Route Table ID as follows:\n\n```\n$ swiro switch -r rtb-xxxxxx -v 10.0.0.1 -I i-xxxxxx\nSwitch the route below setting:\n===\u003e Route Table: route_table (rtb-xxxxxx)\n---\u003e Virtual IP:  10.0.0.1 -------- Src:  src_instance (i-yyyyyy)\n                           \\\\\n                            ======\u003e Dest: i-xxxxxx\nAre you sure? (y/n) [y]: y\nSuccess!!\n```\n\nYou can also switch by specifying Route Table Name instead of Route Table ID.\n\n```\n$ swiro switch -r route_table -v 10.0.0.1 -I dest_instance\n```\n\n## Install\n\nTo install, use `go get`:\n\n```bash\n$ go get -u github.com/taku-k/swiro\n```\n\n## Contribution\n\n1. Fork ([https://github.com/taku-k/swiro/fork](https://github.com/taku-k/swiro/fork))\n1. Create a feature branch\n1. Commit your changes\n1. Rebase your local changes against the master branch\n1. Run test suite with the `go test ./...` command and confirm that it passes\n1. Run `gofmt -s`\n1. Create a new Pull Request\n\n## Release\n\nPrerequisite:\n\n```bash\n$ go get github.com/tcnksm/ghr\n$ go get github.com/Songmu/ghch/cmd/ghch\n```\n\nWhen you'd like to release master branch as v0.2.8:\n\n```bash\n$ ./release.sh v0.2.8\n```\n\n## Author\n\n[taku-k](https://github.com/taku-k)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhatena%2Fswiro","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhatena%2Fswiro","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhatena%2Fswiro/lists"}