-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FEATURE] multidomain-domainnames (#59)
* Implemented util.read_domainfile This reads a given json file containing a dict with bat_device names as keys and domain_names as values. * Provided an example domainfile. * Added a new parameter to spcify where to read the domainfile from. It's optional. * Altered the domain_code-provider in order to support domaincode-files. Given a dcf-path, the provider tries to return the domaincode related to a batadv_dev, like trier did earlier in their code. If it cannot find a match, it returns whatever was provided as 'domaincode' via '-n' in the commandline, which makes it effectively a default value for unkown domains and a nice fallback. * updated util.read_dumainfile removed unnecessary return variable Co-Authored-By: Martin Weinelt <[email protected]> * updated domainfile example to reflect domaincodes * util: removed redundant line * README: add domain_code-file documentation * Fixed type in 'return', however it got there. * Added per batman iface domaincode overrides * readme: reflects per batinterface domaincode * domaincodefile: changed format to one-key-dict The file now holds a key called 'domaincodes' and below the assignments. This allows a transition from domaincodefile to configfile in the future, if wanted. Co-authored-by: Martin Weinelt <[email protected]>
- Loading branch information
1 parent
5395852
commit acee436
Showing
5 changed files
with
66 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"domaincodes": { | ||
"bat0": "dom0", | ||
"bat10": "dom10", | ||
"bat11": "dom11", | ||
"bat12": "dom12", | ||
"bat13": "dom13", | ||
"bat14": "dom14", | ||
"bat15": "dom15", | ||
"bat16": "dom16", | ||
"bat17": "dom17", | ||
"bat18": "dom18", | ||
"bat19": "dom19", | ||
"bat20": "dom20", | ||
"bat21": "dom21", | ||
"bat22": "dom22", | ||
"bat23": "dom23", | ||
"bat99": "dom99" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters