Documentation
¶
Index ¶
- func NewCmdAdd(f *cmdutil.Factory, runF func(context.Context, *AddOptions) error) *cobra.Command
- func NewCmdBypass(f *cmdutil.Factory, runF func(context.Context, *BypassOptions) error) *cobra.Command
- func NewCmdDisable(f *cmdutil.Factory, runF func(context.Context, *DisableOptions) error) *cobra.Command
- func NewCmdDown(f *cmdutil.Factory, runF func(context.Context, *DownOptions) error) *cobra.Command
- func NewCmdEnable(f *cmdutil.Factory, runF func(context.Context, *EnableOptions) error) *cobra.Command
- func NewCmdFirewall(f *cmdutil.Factory) *cobra.Command
- func NewCmdList(f *cmdutil.Factory, runF func(context.Context, *ListOptions) error) *cobra.Command
- func NewCmdReload(f *cmdutil.Factory, runF func(context.Context, *ReloadOptions) error) *cobra.Command
- func NewCmdRemove(f *cmdutil.Factory, runF func(context.Context, *RemoveOptions) error) *cobra.Command
- func NewCmdRotateCA(f *cmdutil.Factory, runF func(context.Context, *RotateCAOptions) error) *cobra.Command
- func NewCmdServe(f *cmdutil.Factory, runF func(context.Context, *UpOptions) error) *cobra.Command
- func NewCmdStatus(f *cmdutil.Factory, runF func(context.Context, *StatusOptions) error) *cobra.Command
- func NewCmdUp(f *cmdutil.Factory, runF func(context.Context, *UpOptions) error) *cobra.Command
- type AddOptions
- type BypassDashboardConfig
- type BypassDashboardResult
- type BypassOptions
- type DisableOptions
- type DownOptions
- type EnableOptions
- type ListOptions
- type ReloadOptions
- type RemoveOptions
- type RotateCAOptions
- type StatusOptions
- type UpOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCmdBypass ¶
func NewCmdBypass(f *cmdutil.Factory, runF func(context.Context, *BypassOptions) error) *cobra.Command
NewCmdBypass creates the firewall bypass command.
func NewCmdDisable ¶
func NewCmdDisable(f *cmdutil.Factory, runF func(context.Context, *DisableOptions) error) *cobra.Command
NewCmdDisable creates the firewall disable command.
func NewCmdDown ¶
NewCmdDown creates the firewall down command.
func NewCmdEnable ¶
func NewCmdEnable(f *cmdutil.Factory, runF func(context.Context, *EnableOptions) error) *cobra.Command
NewCmdEnable creates the firewall enable command.
func NewCmdFirewall ¶
NewCmdFirewall creates the parent command for firewall management.
func NewCmdList ¶
NewCmdList creates the firewall list command.
func NewCmdReload ¶
func NewCmdReload(f *cmdutil.Factory, runF func(context.Context, *ReloadOptions) error) *cobra.Command
NewCmdReload creates the firewall reload command.
func NewCmdRemove ¶
func NewCmdRemove(f *cmdutil.Factory, runF func(context.Context, *RemoveOptions) error) *cobra.Command
NewCmdRemove creates the firewall remove command.
func NewCmdRotateCA ¶
func NewCmdRotateCA(f *cmdutil.Factory, runF func(context.Context, *RotateCAOptions) error) *cobra.Command
NewCmdRotateCA creates the firewall rotate-ca command.
func NewCmdServe ¶
NewCmdServe creates the hidden blocking daemon entrypoint. This is invoked by the detached firewall startup path.
func NewCmdStatus ¶
func NewCmdStatus(f *cmdutil.Factory, runF func(context.Context, *StatusOptions) error) *cobra.Command
NewCmdStatus creates the firewall status command.
Types ¶
type AddOptions ¶
type AddOptions struct {
IOStreams *iostreams.IOStreams
Firewall func(context.Context) (firewall.FirewallManager, error)
Domain string
Proto string
Port int
}
AddOptions holds the options for the firewall add command.
type BypassDashboardConfig ¶
BypassDashboardConfig holds the configuration for the bypass dashboard.
type BypassDashboardResult ¶
type BypassDashboardResult struct {
Err error
Detached bool // user pressed q/Esc (switch to non-interactive)
Interrupted bool // user pressed Ctrl+C (stop bypass)
}
BypassDashboardResult is returned when the dashboard exits.
func RunBypassDashboard ¶
func RunBypassDashboard(ios *iostreams.IOStreams, cfg BypassDashboardConfig, ch <-chan any) BypassDashboardResult
RunBypassDashboard runs the interactive bypass dashboard.
type BypassOptions ¶
type BypassOptions struct {
IOStreams *iostreams.IOStreams
TUI *tui.TUI
ProjectManager func() (project.ProjectManager, error)
Firewall func(context.Context) (firewall.FirewallManager, error)
Agent string
Duration time.Duration
Stop bool
NonInteractive bool
}
BypassOptions holds the options for the firewall bypass command.
type DisableOptions ¶
type DisableOptions struct {
IOStreams *iostreams.IOStreams
ProjectManager func() (project.ProjectManager, error)
Firewall func(context.Context) (firewall.FirewallManager, error)
Agent string
}
DisableOptions holds the options for the firewall disable command.
type DownOptions ¶
DownOptions holds the options for the firewall down command.
type EnableOptions ¶
type EnableOptions struct {
IOStreams *iostreams.IOStreams
ProjectManager func() (project.ProjectManager, error)
Firewall func(context.Context) (firewall.FirewallManager, error)
Agent string
}
EnableOptions holds the options for the firewall enable command.
type ListOptions ¶
type ListOptions struct {
IOStreams *iostreams.IOStreams
TUI *tui.TUI
Firewall func(context.Context) (firewall.FirewallManager, error)
Format *cmdutil.FormatFlags
}
ListOptions holds the options for the firewall list command.
type ReloadOptions ¶
type ReloadOptions struct {
IOStreams *iostreams.IOStreams
Firewall func(context.Context) (firewall.FirewallManager, error)
}
ReloadOptions holds the options for the firewall reload command.
type RemoveOptions ¶
type RemoveOptions struct {
IOStreams *iostreams.IOStreams
Firewall func(context.Context) (firewall.FirewallManager, error)
Domain string
Proto string
Port int
}
RemoveOptions holds the options for the firewall remove command.
type RotateCAOptions ¶
type RotateCAOptions struct {
IOStreams *iostreams.IOStreams
Config func() (config.Config, error)
Firewall func(context.Context) (fwpkg.FirewallManager, error)
}
RotateCAOptions holds the options for the firewall rotate-ca command.
type StatusOptions ¶
type StatusOptions struct {
IOStreams *iostreams.IOStreams
Firewall func(context.Context) (firewall.FirewallManager, error)
Format *cmdutil.FormatFlags
}
StatusOptions holds the options for the firewall status command.