Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/muka/ddns
Simple restful dynamic DNS service
https://github.com/muka/ddns
dns-server dynamic-dns golang grpc
Last synced: 3 months ago
JSON representation
Simple restful dynamic DNS service
- Host: GitHub
- URL: https://github.com/muka/ddns
- Owner: muka
- License: mit
- Created: 2017-06-20T05:29:51.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-06-01T05:44:56.000Z (over 5 years ago)
- Last Synced: 2024-10-04T13:10:52.062Z (4 months ago)
- Topics: dns-server, dynamic-dns, golang, grpc
- Language: Go
- Homepage:
- Size: 53.7 KB
- Stars: 29
- Watchers: 4
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Dynamic DNS Service
Simple dynamic DNS service for LAN use
## Supported record
- A / AAAA + (PTR)
- CNAME
- MX## Running with docker
```bash
docker run -v `pwd`/data:/data raptorbox/ddns-amd64 --debug
```## Setup
Run `make setup` to install go dependencies and a local protoc setup
## Running
```bash
make build
./build/ddns --debug
```or `go run cli/cli --debug`
## Rest API
Offers a gRPC (`:50551`) and HTTP/JSON (`:5551`) endpoint. See also generated [./api/api.swagger.json](./api/api.swagger.json) for usage reference.
### Create a record
```bash
curl -X POST http://localhost:5551/v1/record \
-H 'content-type: application/json' \
-d '{
"ip": "127.0.0.1",
"domain": "foobar.local.lan",
"type": "A",
"expires": 1498454965
}'
```### Remove Record
`curl -X DELETE http://localhost:5551/v1/record/foobar.local.lan/A`
### Test Record
`nslookup foobar.local.lan localhost -port=10053`
## nsupdate support
Run `go run main.go --tsig some_key:c29tZV9rZXk=`
### Using nsupdate
Update with `nsupdate nsupdate.txt`
### Test records
`nslookup test1.local.lan localhost -port=10053`
## Credits
Inspired by [this post](http://mkaczanowski.com/golang-build-dynamic-dns-service-go/) of Mateusz Kaczanowski
## License
MIT License