templates

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 26, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewPlaybookBrVlanYamlTemplate added in v0.4.0

func NewPlaybookBrVlanYamlTemplate() *template.Template

func NewPlaybookDaemonsTemplate

func NewPlaybookDaemonsTemplate() *template.Template

func NewPlaybookFibcYamlTemplate

func NewPlaybookFibcYamlTemplate() *template.Template

func NewPlaybookFrrConfTemplate

func NewPlaybookFrrConfTemplate() *template.Template

func NewPlaybookGoBGPConfTemplate

func NewPlaybookGoBGPConfTemplate() *template.Template

func NewPlaybookGoBGPdConfTemplate

func NewPlaybookGoBGPdConfTemplate() *template.Template

func NewPlaybookInventoryTemplate

func NewPlaybookInventoryTemplate() *template.Template

func NewPlaybookLXDProfileTemplate

func NewPlaybookLXDProfileTemplate() *template.Template

func NewPlaybookNetplanYamlTemplate

func NewPlaybookNetplanYamlTemplate() *template.Template

func NewPlaybookRibtdConfTemplate

func NewPlaybookRibtdConfTemplate() *template.Template

func NewPlaybookRibxdConfTemplate

func NewPlaybookRibxdConfTemplate() *template.Template

func NewPlaybookSnmpConfTemplate added in v0.4.0

func NewPlaybookSnmpConfTemplate() *template.Template

func NewPlaybookSnmpProxydConfTemplate

func NewPlaybookSnmpProxydConfTemplate() *template.Template

func NewPlaybookSnmpProxydYamlTemplate

func NewPlaybookSnmpProxydYamlTemplate() *template.Template

func NewPlaybookSnmpdConfTemplate added in v0.4.0

func NewPlaybookSnmpdConfTemplate() *template.Template

func NewPlaybookSysctlConfTemplate

func NewPlaybookSysctlConfTemplate() *template.Template

func NewPlaybookTemplate

func NewPlaybookTemplate() *template.Template

Types

type Playbook

type Playbook struct {
	Name string
}

func NewPlaybook

func NewPlaybook(name string) *Playbook

func (*Playbook) Execute

func (p *Playbook) Execute(w io.Writer) error

type PlaybookBrVlanVlan added in v0.4.0

type PlaybookBrVlanVlan struct {
	Name string
	Id   uint
	Ids  []uint
}

func NewPlaybookBrVlanVlan added in v0.4.0

func NewPlaybookBrVlanVlan(ifname string) *PlaybookBrVlanVlan

type PlaybookBrVlanYaml added in v0.4.0

type PlaybookBrVlanYaml struct {
	Vlans []*PlaybookBrVlanVlan
}

func NewPlaybookBrVlanYaml added in v0.4.0

func NewPlaybookBrVlanYaml() *PlaybookBrVlanYaml

func (*PlaybookBrVlanYaml) AddAccessPort added in v0.4.0

func (p *PlaybookBrVlanYaml) AddAccessPort(index uint, vid uint)

func (*PlaybookBrVlanYaml) AddTrunkPort added in v0.4.0

func (p *PlaybookBrVlanYaml) AddTrunkPort(index uint, vids ...uint)

func (*PlaybookBrVlanYaml) Execute added in v0.4.0

func (p *PlaybookBrVlanYaml) Execute(w io.Writer) error

type PlaybookDaemon

type PlaybookDaemon struct {
	Name string
	Arg  string
}

func NewPlaybookDaemon

func NewPlaybookDaemon(name, arg string) *PlaybookDaemon

type PlaybookDaemons

type PlaybookDaemons struct {
	// contains filtered or unexported fields
}

func NewPlaybookDaemons

func NewPlaybookDaemons() *PlaybookDaemons

func (*PlaybookDaemons) Execute

func (p *PlaybookDaemons) Execute(w io.Writer) error

func (*PlaybookDaemons) Set

func (p *PlaybookDaemons) Set(daemon, arg string)

func (*PlaybookDaemons) SetMap

func (p *PlaybookDaemons) SetMap(m map[string]string)

func (*PlaybookDaemons) SetNo

func (p *PlaybookDaemons) SetNo(daemons ...string)

func (*PlaybookDaemons) SetYes

func (p *PlaybookDaemons) SetYes(daemons ...string)

type PlaybookFibcPort

type PlaybookFibcPort struct {
	PPort uint
	LPort uint
}

func NewPlaybookFibcPort

func NewPlaybookFibcPort(pport, lport uint) *PlaybookFibcPort

func (*PlaybookFibcPort) Ifname

func (p *PlaybookFibcPort) Ifname() string

type PlaybookFibcYaml

type PlaybookFibcYaml struct {
	Desc   string
	ReID   string
	DpName string
	DpID   uint64
	DpMode string
	Ports  []*PlaybookFibcPort
}

func NewPlaybookFibcYaml

func NewPlaybookFibcYaml(reID, dpName string) *PlaybookFibcYaml

func (*PlaybookFibcYaml) AddPort

func (p *PlaybookFibcYaml) AddPort(pport, lport uint)

func (*PlaybookFibcYaml) AddPorts

func (p *PlaybookFibcYaml) AddPorts(m map[uint]uint)

func (*PlaybookFibcYaml) Execute

func (p *PlaybookFibcYaml) Execute(w io.Writer) error

type PlaybookFrrConf

type PlaybookFrrConf struct {
	RouterID string
	Ifnames  []string
}

func NewPlaybookFrrConf

func NewPlaybookFrrConf(routerID string) *PlaybookFrrConf

func (*PlaybookFrrConf) AddIface

func (p *PlaybookFrrConf) AddIface(index, vid uint)

func (*PlaybookFrrConf) Execute

func (p *PlaybookFrrConf) Execute(w io.Writer) error

type PlaybookGoBGPConf

type PlaybookGoBGPConf struct {
}

func NewPlaybookGoBGPConf

func NewPlaybookGoBGPConf() *PlaybookGoBGPConf

func (*PlaybookGoBGPConf) Execute

func (p *PlaybookGoBGPConf) Execute(w io.Writer) error

type PlaybookGoBGPdConf

type PlaybookGoBGPdConf struct {
	RouterID string
	AS       uint
}

func NewPlaybookGoBGPdConf

func NewPlaybookGoBGPdConf() *PlaybookGoBGPdConf

func (*PlaybookGoBGPdConf) Execute

func (p *PlaybookGoBGPdConf) Execute(w io.Writer) error

type PlaybookInventory

type PlaybookInventory struct {
	Name  string
	Hosts []string
}

func NewPlaybookInventory

func NewPlaybookInventory() *PlaybookInventory

func (*PlaybookInventory) AddHost

func (p *PlaybookInventory) AddHost(host string)

func (*PlaybookInventory) AddHosts

func (p *PlaybookInventory) AddHosts(hosts ...string)

func (*PlaybookInventory) Execute

func (p *PlaybookInventory) Execute(w io.Writer) error

type PlaybookNetplanEth

type PlaybookNetplanEth struct {
	Name string
	Mtu  uint16
}

func NewPlaybookNetplanEth

func NewPlaybookNetplanEth(name string, mtu uint16) *PlaybookNetplanEth

type PlaybookNetplanVlan

type PlaybookNetplanVlan struct {
	Link string
	Vid  uint
}

func NewPlaybookNetplanVlan

func NewPlaybookNetplanVlan(link string, vid uint) *PlaybookNetplanVlan

type PlaybookNetplanYaml

type PlaybookNetplanYaml struct {
	Eths  []*PlaybookNetplanEth
	Vlans []*PlaybookNetplanVlan
}

func NewPlaybookNetplanYaml

func NewPlaybookNetplanYaml() *PlaybookNetplanYaml

func (*PlaybookNetplanYaml) AddEth

func (p *PlaybookNetplanYaml) AddEth(index uint, mtu uint16)

func (*PlaybookNetplanYaml) AddVlan

func (p *PlaybookNetplanYaml) AddVlan(index uint, vid uint)

func (*PlaybookNetplanYaml) Execute

func (p *PlaybookNetplanYaml) Execute(w io.Writer) error

type PlaybookRibtdConf

type PlaybookRibtdConf struct {
}

func NewPlaybookRibtdConf

func NewPlaybookRibtdConf() *PlaybookRibtdConf

func (*PlaybookRibtdConf) Execute

func (p *PlaybookRibtdConf) Execute(w io.Writer) error

type PlaybookRibxdConf

type PlaybookRibxdConf struct {
	NID  uint8
	ReID string
	Name string
	RT   string
	RD   string
	Vpn  bool
}

func NewPlaybookRibxdConf

func NewPlaybookRibxdConf() *PlaybookRibxdConf

func (*PlaybookRibxdConf) Execute

func (p *PlaybookRibxdConf) Execute(w io.Writer) error

type PlaybookSnmpConf added in v0.4.0

type PlaybookSnmpConf struct {
}

func NewPlaybookSnmpConf added in v0.4.0

func NewPlaybookSnmpConf() *PlaybookSnmpConf

func (*PlaybookSnmpConf) Execute added in v0.4.0

func (p *PlaybookSnmpConf) Execute(w io.Writer) error

type PlaybookSnmpProxydConf

type PlaybookSnmpProxydConf struct {
	Host           bool
	SnmpProxydAddr string
}

func NewPlaybookSnmpProxydConf

func NewPlaybookSnmpProxydConf(host bool) *PlaybookSnmpProxydConf

func (*PlaybookSnmpProxydConf) Execute

func (p *PlaybookSnmpProxydConf) Execute(w io.Writer) error

type PlaybookSnmpProxydYaml

type PlaybookSnmpProxydYaml struct {
	Trap2Map map[string]uint
}

func NewPlaybookSnmpProxydYaml

func NewPlaybookSnmpProxydYaml() *PlaybookSnmpProxydYaml

func (*PlaybookSnmpProxydYaml) AddTrap2Map

func (p *PlaybookSnmpProxydYaml) AddTrap2Map(pport, lport uint)

func (*PlaybookSnmpProxydYaml) Execute

func (p *PlaybookSnmpProxydYaml) Execute(w io.Writer) error

type PlaybookSnmpdConf added in v0.4.0

type PlaybookSnmpdConf struct {
	SnmpProxydAddr      string
	LinkMonitorInterval uint
}

func NewPlaybookSnmpdConf added in v0.4.0

func NewPlaybookSnmpdConf() *PlaybookSnmpdConf

func (*PlaybookSnmpdConf) Execute added in v0.4.0

func (p *PlaybookSnmpdConf) Execute(w io.Writer) error

type PlaybookSysctlConf

type PlaybookSysctlConf struct {
	SockBufSize uint
	MplsLabel   uint
	// contains filtered or unexported fields
}

func NewPlaybookSysctlConf

func NewPlaybookSysctlConf() *PlaybookSysctlConf

func (*PlaybookSysctlConf) AddIface

func (p *PlaybookSysctlConf) AddIface(index, vid uint)

func (*PlaybookSysctlConf) Execute

func (p *PlaybookSysctlConf) Execute(w io.Writer) error

func (*PlaybookSysctlConf) Ifaces

func (p *PlaybookSysctlConf) Ifaces() []string

type PlybookLXDProfile

type PlybookLXDProfile struct {
	Name        string
	MngIface    string
	BridgeIface string
	Mtu         uint16
	Ports       []uint
}

func NewPlaybookLXDProfile

func NewPlaybookLXDProfile() *PlybookLXDProfile

func (*PlybookLXDProfile) AddPort

func (p *PlybookLXDProfile) AddPort(pport uint)

func (*PlybookLXDProfile) AddPorts

func (p *PlybookLXDProfile) AddPorts(pports ...uint)

func (*PlybookLXDProfile) Execute

func (p *PlybookLXDProfile) Execute(w io.Writer) error

func (*PlybookLXDProfile) IfaceIndex

func (p *PlybookLXDProfile) IfaceIndex(i uint) uint

func (*PlybookLXDProfile) Ifaces

func (p *PlybookLXDProfile) Ifaces() []string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL