Billionmail/BillionMail · error
missing 'services' in config
Error message
missing 'services' in config
What it means
Type assertion guard at the top of rebuildPostfixServiceNetworks: the parsed docker-compose config map has no 'services' key of type map[string]interface{}, so the YAML is missing (or has a differently shaped) top-level services section and the Postfix service networks cannot be rebuilt. This is a structural check on the parsed compose document, not a runtime IO failure.
Source
Thrown at core/internal/service/multi_ip_domain/config_manager.go:471
result = append(result, lines[postfixNetworksEndIdx:]...)
}
return result, nil
}
// deepCopy performs a deep copy of any value using YAML marshal/unmarshal
func deepCopy(src interface{}) interface{} {
data, _ := yaml.Marshal(src)
var copy interface{}
yaml.Unmarshal(data, ©)
return copy
}
// rebuildPostfixServiceNetworks Rebuild Postfix service network configuration
func (m *ConfigManager) rebuildPostfixServiceNetworks(config map[string]interface{}, configs []map[string]interface{}) error {
services, ok := config["services"].(map[string]interface{})
if !ok {
return fmt.Errorf("missing 'services' in config")
}
postfix, ok := services["postfix-billionmail"].(map[string]interface{})
if !ok {
return fmt.Errorf("postfix-billionmail service not found")
}
// Get current networks (preserve original)
networks, ok := postfix["networks"].(map[string]interface{})
if !ok {
networks = make(map[string]interface{})
}
// === 1. Remove all custom networks (except default billionmail-network) ===
for name := range networks {
if name != "billionmail-network" {
delete(networks, name)
g.Log().Debugf(context.Background(), "Removed old custom network: %s", name)View on GitHub (pinned to fc36c76c05)
Solutions
- Validate docker-compose.yml structure (services key present at top level) before calling rebuild functions
- Fix or restore the compose file so 'services:' exists with service mappings underneath
- Use a stricter YAML schema check on load to reject malformed compose files early with a clearer message
Defensive patterns
Strategy: type-guard
When it happens
Trigger: Thrown at core/internal/service/multi_ip_domain/config_manager.go:471 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of Billionmail/BillionMail@fc36c76c05 (2026-09-05).
Data as JSON: /api/errors/51c8d031fc59ecc5.
Report an issue: GitHub.