完善证书申请续期与安装初始化流程

This commit is contained in:
xuans committed 2026-08-27 00:31:40 +08:00
1 parent fd8d8608f5
commit 07636abe44
66 files changed
+9470 -165

No files matched your search

+28
View File
@@ -0,0 +1,28 @@
package firewall
import "context"
const BackendNone = "none"
type Result struct {
Backend string `json:"backend"`
RuleName string `json:"rule_name,omitempty"`
Port int `json:"port"`
Created bool `json:"created"`
Message string `json:"message"`
}
type Manager interface {
OpenTCP(ctx context.Context, port int) (Result, error)
Rollback(ctx context.Context, result Result) error
}
type CommandResult struct {
Output []byte
ExitCode int
}
type Runner interface {
LookPath(name string) (string, error)
Run(ctx context.Context, name string, args ...string) (CommandResult, error)
}