secubox-openwrt/package/secubox/secubox-app-streamlit-control/Makefile
CyberMind-FR 9081444c7a feat(streamlit-control): Phase 3 - auto-refresh, permissions, UI improvements
Streamlit Control Dashboard Phase 3:
- Add auto-refresh toggle to all main pages (10s/30s/60s intervals)
- Add permission-aware UI with can_write() and is_admin() helpers
- Containers page: tabs (All/Running/Stopped), search filter, info panels
- Security page: better CrowdSec parsing, threat table, raw data viewer
- Streamlit apps page: restart button, delete confirmation dialog
- Network page: HAProxy filter, WireGuard/DNS placeholders

fix(crowdsec-dashboard): Handle RPC error codes in overview.js

Fix TypeError when CrowdSec RPC returns error code instead of object.
Added type check to treat non-objects as empty {} in render/pollData.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-11 14:54:30 +01:00

56 lines
1.4 KiB
Makefile

include $(TOPDIR)/rules.mk
PKG_NAME:=secubox-app-streamlit-control
PKG_VERSION:=1.0.0
PKG_RELEASE:=1
include $(INCLUDE_DIR)/package.mk
define Package/secubox-app-streamlit-control
SECTION:=secubox
CATEGORY:=SecuBox
SUBMENU:=Apps
TITLE:=SecuBox Control Dashboard
DEPENDS:=+secubox-app-streamlit-forge +python3 +python3-requests
PKGARCH:=all
endef
define Package/secubox-app-streamlit-control/description
Streamlit-based LuCI replacement dashboard.
Provides a modern web UI for managing SecuBox services,
containers, sites, network, and security.
KISS design inspired by luci-app-metablogizer.
endef
define Package/secubox-app-streamlit-control/conffiles
/etc/config/streamlit-control
endef
define Build/Compile
endef
define Package/secubox-app-streamlit-control/install
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_CONF) ./files/etc/config/streamlit-control $(1)/etc/config/
$(INSTALL_DIR) $(1)/usr/share/streamlit-control
$(CP) ./files/usr/share/streamlit-control/* $(1)/usr/share/streamlit-control/
endef
define Package/secubox-app-streamlit-control/postinst
#!/bin/sh
[ -n "$${IPKG_INSTROOT}" ] || {
# Register with Streamlit Forge
if [ -x /usr/sbin/slforge ]; then
/usr/sbin/slforge register control \
--name "SecuBox Control" \
--port 8531 \
--path /usr/share/streamlit-control \
--entry app.py 2>/dev/null || true
fi
}
exit 0
endef
$(eval $(call BuildPackage,secubox-app-streamlit-control))