add readme and license

This commit is contained in:
tchivert committed 2023-06-30 15:40:33 +02:00
1 parent 0923ae48cd
commit 50fcc8894d
2 files changed
+75

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2023, tchivert
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+54
View File
@@ -0,0 +1,54 @@
# rdns-go
rdns is a reverse DNS proxy resolver written in Go. It acts as a DNS server, forwarding DNS queries to configured nameservers and returning the corresponding reverse DNS records.
## Building
To build the rdns-go project, you need to have Go installed. Follow the official Go installation instructions for your operating system.
Once Go is installed, clone the rdns-go repository:
```shell
git clone https://git.rznet.fr/razian/rdns-go
cd rdns-go
```
Build the rdns binary:
```shell
go build
```
This will create a `rdns` binary in the project directory.
## Usage
The rdns-go project can be started using the provided docker-compose.yml file. Modify the environment variables in the docker-compose.yml file to customize the configuration.
```shell
docker-compose up -d
```
This command will start the rdns-go container in the background.
## Configuration
The rdns-go project can be configured using the following environment variables in the `docker-compose.yml` file:
- `BLOCKLIST` (default: /etc/rdns/blocklist.txt): The path to the blocklist file. This file contains a list of domain names to block.
- `ZONES` (default: /etc/rdns/rdns.zones): The path to the zones file. This file contains custom zone information.
- `NS` (default: 9.9.9.9:1.1.1.1): The nameservers to use for DNS resolution.
- `TTL` (default: 60): The time-to-live value for cached queries (in minutes).
- `TLS` (default: true): Whether to use TLS to contact the resolver.
- `LOGS` (default: false): Whether to enable query logging.
- `METRICS` (default: false): Whether to enable Prometheus metrics.
To customize the rdns-go configuration, modify the corresponding environment variables.
### Acknowledgments
This project uses code from [miekg/dns](https://github.com/miekg/dns) and [patrickmn/go-cache](https://github.com/patrickmn/go-cache).
## License
This project is licensed under the MIT License. See the [LICENSE](https://git.rznet.fr/razian/rdns-go/src/branch/main/LICENSE) file for more information.