Skip to content

Commit 6b36963

Browse files
committed
updated readme
1 parent 8922083 commit 6b36963

File tree

2 files changed

+84
-18
lines changed

2 files changed

+84
-18
lines changed

README.md

+42-9
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,34 @@
11
# kdb_cookbook_library
22

3-
Provides resources to interact with the key database of the elektra configuration framework (https://www.libelektra.org).
3+
Elektra stores configuration in a global, hierarchical key database.
4+
It supports seamless integration and introspection by mounting configuration files into the key database.
5+
[See the homepage for more information.](https://www.libelektra.org).
6+
This cookbook configures applications with Elektra.
47

58
## Usage
69

7-
The kdbset resource allows to create or update and delete keys in the key database. The kdbmount resource mounts and unmounts configuration files.
8-
The default recipe gives an example on how the resources could be used for new recipes.
10+
The kdbset resource allows us to create (or update) and delete keys in the key database.
11+
The kdbmount resource mounts (and unmounts) configuration files into the key database.
12+
The default recipe gives an example on how the resources can be used for new recipes.
913

1014
## Requirements
1115

12-
* elektra (https://github.com/ElektraInitiative/libelektra/blob/master/doc/INSTALL.md)
16+
* Elektra (https://www.libelektra.org/docgettingstarted/installation)
17+
18+
## Platform Support
19+
20+
* Linux
21+
* BSD
22+
* Mac OS X
23+
* Windows (mingw)
1324

1425
## Default Recipe
1526

16-
The default recipe demonstrates how to add a new configuration value to the etc/hosts file. In the first step the file
17-
is mounted into the key database using the system namespace. A new configuration value is added to the file via kdbset in
18-
the second step. The third step removes the configuration file from the key database. If you open the file afterwards you can
19-
find a new entry. Using the :delete action of kdbset could remove the key from the file.
27+
The default recipe demonstrates how to add a new configuration value to the `/etc/hosts` file:
28+
29+
1. In the first step the file is mounted into the key database using the system namespace.
30+
2. In the second step a new configuration value is added to the file via kdbset.
31+
3. The third step removes the configuration file from the key database. If you open the file afterwards you can find a new entry.
2032

2133
## Resources
2234

@@ -29,6 +41,8 @@ Creates, updates and deletes key from the key database.
2941
* create
3042
* delete
3143

44+
The :delete action of kdbset removes the key from the file.
45+
3246
### Attribute Parameters
3347

3448
| Parameter | Type | Description |
@@ -48,13 +62,15 @@ kdbset '/hosts/ipv4/showthatitworks' do
4862
action :create
4963
end
5064
```
65+
5166
delete existing key
5267

5368
```
5469
kdbset 'system/hosts/ipv4/showthatitworks' do
5570
action :delete
5671
end
5772
```
73+
5874
### kdbmount
5975

6076
Mounts configuration files into the key database und removes them from the same.
@@ -68,7 +84,7 @@ Mounts configuration files into the key database und removes them from the same.
6884
| ------------- |:------:|:--------------------------------------------------------|
6985
| mountpoint | string | where in the database the new backend should be mounted |
7086
| file | string | path to the file that should be mounted |
71-
| plugins | string | list of elektra plugins to be used, each plugin can be <br> configured by a comma separated list of keys=values |
87+
| plugins | string | list of Elektra plugins to be used, each plugin can be <br> configured by a comma separated list of keys=values |
7288

7389
### Examples
7490

@@ -81,10 +97,27 @@ kdbmount 'system/hosts' do
8197
action :create
8298
end
8399
```
100+
84101
unmounts /etc/hosts from the database
85102

86103
```
87104
kdbmount 'system/hosts' do
88105
action :delete
89106
end
90107
```
108+
109+
## License
110+
111+
### BSD 3-Clause License
112+
113+
Copyright (c) 2017, Elektra Initiative Some rights reserved.
114+
115+
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
116+
117+
Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
118+
119+
Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
120+
121+
Neither the name of Elektra nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
122+
123+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

kdb/README.md

+42-9
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,34 @@
11
# kdb_cookbook_library
22

3-
Provides resources to interact with the key database of the elektra configuration framework (https://www.libelektra.org).
3+
Elektra stores configuration in a global, hierarchical key database.
4+
It supports seamless integration and introspection by mounting configuration files into the key database.
5+
[See the homepage for more information.](https://www.libelektra.org).
6+
This cookbook configures applications with Elektra.
47

58
## Usage
69

7-
The kdbset resource allows to create or update and delete keys in the key database. The kdbmount resource mounts and unmounts configuration files.
8-
The default recipe gives an example on how the resources could be used for new recipes.
10+
The kdbset resource allows us to create (or update) and delete keys in the key database.
11+
The kdbmount resource mounts (and unmounts) configuration files into the key database.
12+
The default recipe gives an example on how the resources can be used for new recipes.
913

1014
## Requirements
1115

12-
* elektra (https://github.com/ElektraInitiative/libelektra/blob/master/doc/INSTALL.md)
16+
* Elektra (https://www.libelektra.org/docgettingstarted/installation)
17+
18+
## Platform Support
19+
20+
* Linux
21+
* BSD
22+
* Mac OS X
23+
* Windows (mingw)
1324

1425
## Default Recipe
1526

16-
The default recipe demonstrates how to add a new configuration value to the etc/hosts file. In the first step the file
17-
is mounted into the key database using the system namespace. A new configuration value is added to the file via kdbset in
18-
the second step. The third step removes the configuration file from the key database. If you open the file afterwards you can
19-
find a new entry. Using the :delete action of kdbset could remove the key from the file.
27+
The default recipe demonstrates how to add a new configuration value to the `/etc/hosts` file:
28+
29+
1. In the first step the file is mounted into the key database using the system namespace.
30+
2. In the second step a new configuration value is added to the file via kdbset.
31+
3. The third step removes the configuration file from the key database. If you open the file afterwards you can find a new entry.
2032

2133
## Resources
2234

@@ -29,6 +41,8 @@ Creates, updates and deletes key from the key database.
2941
* create
3042
* delete
3143

44+
The :delete action of kdbset removes the key from the file.
45+
3246
### Attribute Parameters
3347

3448
| Parameter | Type | Description |
@@ -48,13 +62,15 @@ kdbset '/hosts/ipv4/showthatitworks' do
4862
action :create
4963
end
5064
```
65+
5166
delete existing key
5267

5368
```
5469
kdbset 'system/hosts/ipv4/showthatitworks' do
5570
action :delete
5671
end
5772
```
73+
5874
### kdbmount
5975

6076
Mounts configuration files into the key database und removes them from the same.
@@ -68,7 +84,7 @@ Mounts configuration files into the key database und removes them from the same.
6884
| ------------- |:------:|:--------------------------------------------------------|
6985
| mountpoint | string | where in the database the new backend should be mounted |
7086
| file | string | path to the file that should be mounted |
71-
| plugins | string | list of elektra plugins to be used, each plugin can be <br> configured by a comma separated list of keys=values |
87+
| plugins | string | list of Elektra plugins to be used, each plugin can be <br> configured by a comma separated list of keys=values |
7288

7389
### Examples
7490

@@ -81,10 +97,27 @@ kdbmount 'system/hosts' do
8197
action :create
8298
end
8399
```
100+
84101
unmounts /etc/hosts from the database
85102

86103
```
87104
kdbmount 'system/hosts' do
88105
action :delete
89106
end
90107
```
108+
109+
## License
110+
111+
### BSD 3-Clause License
112+
113+
Copyright (c) 2017, Elektra Initiative Some rights reserved.
114+
115+
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
116+
117+
Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
118+
119+
Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
120+
121+
Neither the name of Elektra nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
122+
123+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

0 commit comments

Comments
 (0)