Skip to content

TSDNS-Go is a lightweight and efficient TeamSpeak DNS server implementation written in Go.

License

Notifications You must be signed in to change notification settings

HoneyBBQ/tsdns-go

Repository files navigation

TSDNS-Go

Go Report Card GoDoc License

A lightweight Teamspeak DNS server implementation in Go.

🌟 Highlights

  • 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

📋 Table of Contents

🚀 Installation

go get github.com/honeybbq/tsdns-go

🎯 Quick Start

Here's a minimal example to get you started: Postgres Demo

⚙️ Configuration

TSDNS supports various configuration options through its builder pattern:

server := tsdns.NewServer("0.0.0.0").
    WithRepository(repo).
    WithLogger(customLogger).
    MustBuild()

🏗 Architecture

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

Repository 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
}

🤝 Contributing

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.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

📞 Support

If you have any questions or need help, please:

  1. Check the issues page
  2. Create a new issue if your problem is not already reported
  3. Join our Teamspeak server for live support

About

TSDNS-Go is a lightweight and efficient TeamSpeak DNS server implementation written in Go.

Topics

Resources

License

Stars

Watchers

Forks

Languages