Skip to main content
Glama

tailscale-mcp-server

by pnocera
main.go•952 B
package main import ( "context" "log" "github.com/mark3labs/mcp-go/server" "github.com/pnocera/tailscale-mcp-server/internal/client" "github.com/pnocera/tailscale-mcp-server/internal/config" "github.com/pnocera/tailscale-mcp-server/internal/handlers" ) func main() { cfg, err := config.LoadConfig() if err != nil { log.Fatalf("Failed to load configuration: %v", err) } tailscaleClient, err := client.NewTailscaleClient(cfg) if err != nil { log.Fatalf("Failed to create Tailscale client: %v", err) } if err := tailscaleClient.ValidateConnection(context.Background()); err != nil { log.Fatalf("Failed to validate Tailscale connection: %v", err) } mcpServer := server.NewMCPServer( "tailscale-mcp-server", "1.0.0", server.WithLogging(), ) handler := handlers.NewHandler(tailscaleClient) handler.RegisterTools(mcpServer) if err := server.ServeStdio(mcpServer); err != nil { log.Fatalf("Server error: %v", err) } }

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/pnocera/tailscale-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server