Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ Mu is a collection of apps for everyday use. While other platforms monetize your

- **Home** - Your personalized dashboard
- **Blog** - Thoughtful microblogging
- **Chat** - Discuss topics with AI
- **Chat** - Discuss topics with AI (Web) or federated XMPP chat
- **News** - RSS feeds with AI summaries
- **Video** - Watch YouTube without ads
- **Mail** - Private messaging & email
- **Mail** - Private messaging & email with SMTP
- **Wallet** - Credits and crypto payments

Mu runs as a single Go binary on your own server or use the hosted version at [mu.xyz](https://mu.xyz).
Expand All @@ -31,7 +31,9 @@ Mu runs as a single Go binary on your own server or use the hosted version at [m
- [x] Chat - Discussion rooms
- [x] News - RSS news feed
- [x] Video - YouTube search
- [x] Mail - Private messaging
- [x] Mail - Private messaging
- [x] SMTP - Email server for federation
- [x] XMPP - Chat server for federation
- [x] Wallet - Crypto payments
- [ ] Services - Marketplace, etc

Expand Down Expand Up @@ -188,6 +190,7 @@ Full documentation is available in the [docs](docs/) folder and at `/docs` on an

**Features**
- [Messaging](docs/MESSAGING_SYSTEM.md) - Email and messaging setup
- [XMPP Chat](docs/XMPP_CHAT.md) - Federated chat with XMPP
- [Wallet & Credits](docs/WALLET_AND_CREDITS.md) - Credit system for metered usage

**Reference**
Expand Down
28 changes: 28 additions & 0 deletions app/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ type MemoryStatus struct {
// DKIMStatusFunc is set by main to avoid import cycle
var DKIMStatusFunc func() (enabled bool, domain, selector string)

// XMPPStatusFunc is set by main to avoid import cycle
var XMPPStatusFunc func() map[string]interface{}

// StatusHandler handles the /status endpoint
func StatusHandler(w http.ResponseWriter, r *http.Request) {
// Quick health check endpoint
Expand Down Expand Up @@ -121,6 +124,31 @@ func buildStatus() StatusResponse {
Details: fmt.Sprintf("Port %s", smtpPort),
})

// Check XMPP server
if XMPPStatusFunc != nil {
xmppStatus := XMPPStatusFunc()
enabled, ok := xmppStatus["enabled"].(bool)
if !ok {
enabled = false
}
details := "Not enabled"
if enabled {
domain, domainOk := xmppStatus["domain"].(string)
port, portOk := xmppStatus["port"].(string)
sessions, sessionsOk := xmppStatus["sessions"].(int)
if domainOk && portOk && sessionsOk {
details = fmt.Sprintf("%s:%s (%d sessions)", domain, port, sessions)
} else {
details = "Configuration error"
}
}
services = append(services, StatusCheck{
Name: "XMPP Server",
Status: enabled,
Details: details,
})
}

// Check LLM provider
llmProvider, llmConfigured := checkLLMConfig()
services = append(services, StatusCheck{
Expand Down
Loading