|
# Examples
|
|
# Examples
|
|
|
|
|
|
|
|
All examples are located in `examples/` directory.
|
|
|
|
|
|
The recommended way is to use a Python virtual environment ([installation instructions](https://gitlab.labs.nic.cz/jetconf/jetconf-resolver/wikis/devinstall))
|
|
The recommended way is to use a Python virtual environment ([installation instructions](https://gitlab.labs.nic.cz/jetconf/jetconf-resolver/wikis/devinstall))
|
|
|
|
|
|
**JetConf-Resolver** must be installed.
|
|
**JetConf-Resolver** must be installed.
|
... | @@ -28,7 +30,8 @@ No output means that the JSON data in `example-data.json` is valid. |
... | @@ -28,7 +30,8 @@ No output means that the JSON data in `example-data.json` is valid. |
|
|
|
|
|
This will generate `unbound.conf` and `kresd.conf` files in local files.
|
|
This will generate `unbound.conf` and `kresd.conf` files in local files.
|
|
|
|
|
|
Go to `examples/` directory
|
|
Go to `examples/` directory.
|
|
|
|
|
|
Run `genconf.py` script with path to Json file as parameter
|
|
Run `genconf.py` script with path to Json file as parameter
|
|
```bash
|
|
```bash
|
|
(jetconf-resolver) $ python genconf.py example-data.json
|
|
(jetconf-resolver) $ python genconf.py example-data.json
|
... | @@ -38,10 +41,7 @@ If generated `unbound.conf` is converted to JSON. The result do not have to be t |
... | @@ -38,10 +41,7 @@ If generated `unbound.conf` is converted to JSON. The result do not have to be t |
|
## Convert unbound.conf to json file
|
|
## Convert unbound.conf to json file
|
|
This will convert `unbound.conf` to valid `unb-data.json`
|
|
This will convert `unbound.conf` to valid `unb-data.json`
|
|
|
|
|
|
Go to `tests/unbound-json` directory.
|
|
Go to `examples/` directory.
|
|
```bash
|
|
|
|
(jetconf-resolver) $ cd tests/unbound-json
|
|
|
|
```
|
|
|
|
|
|
|
|
As example configuration file can be used `../complete/unbound.conf` after running `genconf.py`
|
|
As example configuration file can be used `../complete/unbound.conf` after running `genconf.py`
|
|
|
|
|
... | | ... | |