istio: istio.io/istio/tools/istio-iptables/pkg/dependencies Index | Files

package dependencies

import "istio.io/istio/tools/istio-iptables/pkg/dependencies"

Index

Package Files

implementation.go interface.go stub.go

type Dependencies Uses

type Dependencies interface {
    // RunOrFail runs a command and panics, if it fails
    RunOrFail(cmd string, args ...string)
    // Run runs a command
    Run(cmd string, args ...string) error
    // RunQuietlyAndIgnore runs a command quietly and ignores errors
    RunQuietlyAndIgnore(cmd string, args ...string)
}

Dependencies is used as abstraction for the commands used from the operating system

type RealDependencies Uses

type RealDependencies struct {
}

RealDependencies implementation of interface Dependencies, which is used in production

func (*RealDependencies) Run Uses

func (r *RealDependencies) Run(cmd string, args ...string) error

Run runs a command

func (*RealDependencies) RunOrFail Uses

func (r *RealDependencies) RunOrFail(cmd string, args ...string)

RunOrFail runs a command and panics, if it fails

func (*RealDependencies) RunQuietlyAndIgnore Uses

func (r *RealDependencies) RunQuietlyAndIgnore(cmd string, args ...string)

RunQuietlyAndIgnore runs a command quietly and ignores errors

type StdoutStubDependencies Uses

type StdoutStubDependencies struct {
}

StdoutStubDependencies implementation of interface Dependencies, which is used for testing

func (*StdoutStubDependencies) Run Uses

func (s *StdoutStubDependencies) Run(cmd string, args ...string) error

Run runs a command

func (*StdoutStubDependencies) RunOrFail Uses

func (s *StdoutStubDependencies) RunOrFail(cmd string, args ...string)

RunOrFail runs a command and panics, if it fails

func (*StdoutStubDependencies) RunQuietlyAndIgnore Uses

func (s *StdoutStubDependencies) RunQuietlyAndIgnore(cmd string, args ...string)

RunQuietlyAndIgnore runs a command quietly and ignores errors

Package dependencies imports 4 packages (graph) and is imported by 2 packages. Updated 2020-12-19. Refresh now. Tools for package owners.