{"id":13929920,"url":"https://github.com/neptune-networks/peering","last_synced_at":"2025-07-19T12:30:51.484Z","repository":{"id":53872358,"uuid":"262560825","full_name":"neptune-networks/peering","owner":"neptune-networks","description":"A YAML to BIRD configuration generator for transit networks.","archived":false,"fork":false,"pushed_at":"2021-07-03T22:27:06.000Z","size":75,"stargazers_count":26,"open_issues_count":2,"forks_count":6,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-11-26T19:36:38.102Z","etag":null,"topics":["bgp","bird","ixp","network-automation","peering","router-configuration","routing"],"latest_commit_sha":null,"homepage":"https://neptunenetworks.org/","language":"HTML","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/neptune-networks.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}},"created_at":"2020-05-09T11:57:43.000Z","updated_at":"2024-11-26T18:14:17.000Z","dependencies_parsed_at":"2022-08-24T01:10:22.996Z","dependency_job_id":null,"html_url":"https://github.com/neptune-networks/peering","commit_stats":null,"previous_names":[],"tags_count":0,"template":true,"template_full_name":null,"purl":"pkg:github/neptune-networks/peering","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neptune-networks%2Fpeering","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neptune-networks%2Fpeering/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neptune-networks%2Fpeering/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neptune-networks%2Fpeering/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/neptune-networks","download_url":"https://codeload.github.com/neptune-networks/peering/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neptune-networks%2Fpeering/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265934185,"owners_count":23852086,"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":["bgp","bird","ixp","network-automation","peering","router-configuration","routing"],"created_at":"2024-08-07T18:02:37.273Z","updated_at":"2025-07-19T12:30:51.256Z","avatar_url":"https://github.com/neptune-networks.png","language":"HTML","funding_links":[],"categories":["others"],"sub_categories":[],"readme":"# Neptune Networks Peering Config\n\nThis used to be the pipeline to build [Neptune Networks](https://neptunenetworks.org)' BGP peering configuration. At the time when this was in use, Neptune used BIRD `2.0.7` for its core customer routers and border routers. We relied on this pipeline to take templates and YAML and turn them into a BIRD configuration.\n\nThis BGP configuration has been built to be agnostic to Neptune Networks and should work for you as well. An example configuration file can be seen in [`config/router.fqdn.example.yml`](config/router.fqdn.example.yml). Simply create a similar file with the relevant options to your network and execute the generation steps at the bottom of this README.\n\nThe YAML files in [`config/`](config/) go through a transformation step in which they turn into [`bird.conf`](out/router.fqdn.example/bird.conf), [`peers.conf`](out/router.fqdn.example/peers.conf), and [`static.conf`](out/router.fqdn.example/static.conf) files in the [`out/`](out/) directory.\n\n## BGP Community Support\n\nThe BIRD configuration in this repostiory uses [BGP large communities](http://largebgpcommunities.net/) inspired by [RFC8195](https://tools.ietf.org/html/rfc8195).\n\n### Informational\n\nInformational BGP communities offer insight into Neptune's routing policies.\n\n#### Origin\n\n| Community | Description |\n| --------- | ----------- |\n| `YOUR_ASN:101:1` | Originated by you |\n| `YOUR_ASN:101:2` | Learned from IX |\n| `YOUR_ASN:101:3` | Learned from private peer |\n| `YOUR_ASN:101:4` | Learned from transit provider |\n| `YOUR_ASN:101:5` | Learned from customer |\n\n#### Region\n\nOctets in the function field are the numeric country identifier defined by ISO 3166-1.\n\n| Community | Description |\n| --------- | ----------- |\n| `YOUR_ASN:102:840` | Learned in U.S. |\n\n#### Site\n\n| Community | Description |\n| --------- | ----------- |\n| `YOUR_ASN:103:1` | Learned at NY1 |\n\n### Actionable\n\nBGP communities which manipulate the routing policy.\n\n#### Prepends\n\n| Community | Description |\n| --------- | ----------- |\n| `YOUR_ASN:900:1` | Prepend `YOUR_ASN` once on export to all AS's |\n| `YOUR_ASN:900:2` | Prepend `YOUR_ASN` twice on export to all AS's |\n| `YOUR_ASN:900:3` | Prepend `YOUR_ASN` thrice on export to all AS's |\n| `YOUR_ASN:991:xxxxx` | Prepend `YOUR_ASN` once on export to AS `xxxxx` |\n| `YOUR_ASN:992:xxxxx` | Prepend `YOUR_ASN` once on export to AS `xxxxx` |\n| `YOUR_ASN:993:xxxxx` | Prepend `YOUR_ASN` once on export to AS `xxxxx` |\n\n#### NO_EXPORT\n\n| Community | Description |\n| --------- | ----------- |\n| `YOUR_ASN:600:xxxxx` | Do not export to AS `xxxxx` |\n| `YOUR_ASN:601:2` | Do not export to IX peers |\n| `YOUR_ASN:601:3` | Do not export to private peers |\n| `YOUR_ASN:601:4` | Do not export to transit providers |\n| `YOUR_ASN:601:5` | Do not export to customers |\n| `YOUR_ASN:602:840` | Do not export in U.S. |\n| `YOUR_ASN:603:1` | Do not export in NY1 |\n\n## Usage\n\nStart by creating a new `.yml` file in [`config/`](config/) with all of the configurations you'll need. You can use [`config/router.fqdn.example.yml`](config/router.fqdn.example.yml) as a reference.\n\nOnce you've tuned your configuration file to your liking, build the docker image locally:\n\n```\nscript/build\n```\n\nAnd then generate the configuration:\n\n```\nscript/generate\n```\n\nThis will create a file for each of the templates defined in [`/templates`](templates/) without the `.erb` suffix in the [`out/`](out/) directory.\n\nIf you find that you need to make any adjustments to the templates, simply do so and then re-run the generator.\n\n## Staying up to date\n\nIf you use this as a [GitHub Repository template](https://github.blog/2019-06-06-generate-new-repositories-with-repository-templates/), you will occassionally want to sync your version of the repository with the master one located at [neptune-networks/peering](https://github.com/neptune-networks/peering). To do this, you can run the following commands:\n\n```\ngit remote add upstream https://github.com/neptune-networks/peering.git\ngit fetch upstream\ngit merge upstream/master --allow-unrelated-histories\n```\n\n## Roadmap\n\n- [ ] Community-based local pref\n- [ ] PeeringDB max prefix support\n- [ ] Blackhole support\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneptune-networks%2Fpeering","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fneptune-networks%2Fpeering","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneptune-networks%2Fpeering/lists"}