A lightweight Teamspeak DNS server implementation in Go.
- Simple and efficient TCP-based DNS server
- Flexible repository interfaces (PostgreSQL & File storage supported)
- In-memory cache with automatic updates
- Builder pattern for easy configuration
- Structured logging support
go get github.com/honeybbq/tsdns-go
Here's a minimal example to get you started: Postgres Demo
TSDNS supports various configuration options through its builder pattern:
server := tsdns.NewServer("0.0.0.0").
WithRepository(repo).
WithLogger(customLogger).
MustBuild()
TSDNS follows a clean architecture pattern with the following components:
- Server: Core DNS server implementation
- Repository: Interface for data storage (PostgreSQL/File implementations provided)
- Cache: In-memory cache with automatic updates
- Logger: Structured logging interface
type RecordRepository interface {
Find() ([]*Record, error)
FindByDomain(domain string) (*Record, error)
Create(record *Record) error
Delete(domain string) error
DeleteByInstanceID(instanceID int64) error
Close() error
}
Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature
) - Commit your changes (
git commit -m 'Add some AmazingFeature'
) - Push to the branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
If you have any questions or need help, please:
- Check the issues page
- Create a new issue if your problem is not already reported
- Join our Teamspeak server for live support