From 51bb7979db2f781c65ee913ebec962b548aaf30f Mon Sep 17 00:00:00 2001 From: Daniel Akulenok Date: Tue, 23 Aug 2022 12:10:39 +0200 Subject: [PATCH] expand readme --- README.md | 71 ++++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 68 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 5bca6d6..0b4787a 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,56 @@ Or, as I call them "happy accidents". * If you need a variable to be 0 or null, you need to define it as `var: '0'` or `var: 'null'`, otherwise jinja will assume you want it to be empty/null. Normal integers would be defined as `var: 1`, letting jinja type it as an integer. * If a named configuration option has the name 'key' or 'keys', it will be referenced as 'keyname' or 'keylist' respectively. key/keys are reserved values in most languages. +Configuration Grammar +--------------------- +The bind9 role tries to replicate the official ISC bind9 configuration format as close as possible, +only re-implementing them in YAML format. This means that for the most part, +section names are the same as in named.conf but kebab-case ('var-name') is replaced with snake_case ('var_name') +If you are missing some statements in your resulting config, it is most likely because of this. + +The main configuration variable used are a series of bind_*_config variables (See [Role Variables]) that have the following syntax + +``` +bind9_host_config: + - name: FILENAME # The filename of your desired config file. Will overwrite and manage by BIND if used + SECTION_NAME: # The section name of the bind config you want to define. Can be 'acl', 'options', 'zone', etc. + # See: https://bind9.readthedocs.io/en/v9_18_4/reference.html#configuration-file-grammar + + OPTION: # Any option that is valid within the section + - name: # Any option that can be repeated and has a name, will need to have a unique "name" var + addresses: # Any list of addresses, will need to include a list of addresses like so. + # Even if they only contain one element + - 127.0.0.1 + - 127.0.0.2 + SIMPLE_OPTION: string, boolean or integer value + + IP_PORT_DSCP_OPTION: # Any option that is defined as: + #