update irrdb filter

production
186526 2023-01-12 21:23:56 +08:00
parent 1009d5a943
commit 33d9eb2503
2 changed files with 3 additions and 2 deletions

3
.gitignore vendored
View File

@ -1 +1,2 @@
install.sh install.sh
ansible/hosts

View File

@ -1,6 +1,6 @@
function downstream_import_filter(int ASN) { function downstream_import_filter(int ASN) {
if !is_valid() then return false; if !is_valid() then return false;
if bgp_path.last !~ DOWNSTREAM_ASN then return false; if delete(bgp_path, DOWNSTREAM_ASN).len != 0 then return false;
pub_add_communities(ASN, 20); pub_add_communities(ASN, 20);
pub_preprocess_communities(); pub_preprocess_communities();
bgp_local_pref = 500 - bgp_path.len * 10; bgp_local_pref = 500 - bgp_path.len * 10;