secubox-openwrt/package/secubox/secubox-app-smtp-relay/Makefile
CyberMind-FR a345c16425 feat(smtp-relay): Add unified SMTP relay configuration
- New secubox-app-smtp-relay package with centralized SMTP config
- Shared library with send_mail(), send_html_mail(), send_text_mail()
- CLI: smtp-relayctl with status/test/send/configure/admin commands
- RPCD: 5 methods for LuCI integration
- LuCI settings page with mode selection and test button
- Modes: external (SMTP server), local (auto-detect mailserver), direct
- Migrated reporter and bandwidth-manager to use shared library
- Backwards-compatible fallback to legacy per-app config

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-15 16:01:12 +01:00

47 lines
1.2 KiB
Makefile

include $(TOPDIR)/rules.mk
PKG_NAME:=secubox-app-smtp-relay
PKG_VERSION:=1.0.0
PKG_RELEASE:=1
PKG_MAINTAINER:=SecuBox Team <contact@secubox.io>
PKG_LICENSE:=GPL-3.0
include $(INCLUDE_DIR)/package.mk
define Package/secubox-app-smtp-relay
SECTION:=secubox
CATEGORY:=SecuBox
SUBMENU:=System
TITLE:=SecuBox Unified SMTP Relay
DEPENDS:=+msmtp
PKGARCH:=all
endef
define Package/secubox-app-smtp-relay/description
Centralized SMTP relay configuration for all SecuBox services.
Provides a shared mail library and CLI tool for sending emails.
Supports external SMTP servers, local mailserver auto-detection,
and direct delivery modes.
endef
define Package/secubox-app-smtp-relay/conffiles
/etc/config/smtp-relay
endef
define Build/Compile
endef
define Package/secubox-app-smtp-relay/install
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_CONF) ./files/etc/config/smtp-relay $(1)/etc/config/smtp-relay
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) ./files/usr/sbin/smtp-relayctl $(1)/usr/sbin/smtp-relayctl
$(INSTALL_DIR) $(1)/usr/lib/secubox/mail
$(INSTALL_DATA) ./files/usr/lib/secubox/mail/smtp-relay.sh $(1)/usr/lib/secubox/mail/smtp-relay.sh
endef
$(eval $(call BuildPackage,secubox-app-smtp-relay))