feat: add standalone controlplane support

This commit is contained in:
xboard
2026-04-11 05:36:59 +08:00
parent e9672fbdbe
commit 598b6b531b
34 changed files with 2383 additions and 707 deletions
+3 -3
View File
@@ -3,11 +3,11 @@ package kernel
import (
"strings"
"github.com/cedar2025/xboard-node/internal/panel"
"github.com/cedar2025/xboard-node/internal/model"
)
// NeedsGeoIP returns true when any panel route rule contains a "geoip:" match entry.
func NeedsGeoIP(routes []panel.RouteRule) bool {
func NeedsGeoIP(routes []model.RouteRule) bool {
for _, r := range routes {
for _, m := range r.Match {
if strings.HasPrefix(m, "geoip:") {
@@ -19,7 +19,7 @@ func NeedsGeoIP(routes []panel.RouteRule) bool {
}
// NeedsGeoSite returns true when any panel route rule contains a "geosite:" match entry.
func NeedsGeoSite(routes []panel.RouteRule) bool {
func NeedsGeoSite(routes []model.RouteRule) bool {
for _, r := range routes {
for _, m := range r.Match {
if strings.HasPrefix(m, "geosite:") {