vlan

package
Version: v0.0.0-...-e560ebb Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2021 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AddVlanCmd = &subcommands.Command{
	UsageLine: "vlan",
	ShortDesc: "Add vlan configuration for browser machine",
	LongDesc:  cmdhelp.AddVlanLongDesc,
	CommandRun: func() subcommands.CommandRun {
		c := &addVlan{}
		c.authFlags.Register(&c.Flags, site.DefaultAuthOptions)
		c.envFlags.Register(&c.Flags)
		c.commonFlags.Register(&c.Flags)

		c.Flags.StringVar(&c.name, "name", "", "name of the vlan")
		c.Flags.StringVar(&c.cidrBlock, "cidr-block", "", "the cidr block of the vlan")
		c.Flags.StringVar(&c.description, "desc", "", "description of the vlan")
		c.Flags.Var(flag.StringSlice(&c.zones), "zone", "zone of the vlan, can be specified multiple times."+cmdhelp.ZoneHelpText)
		c.Flags.StringVar(&c.freeStartIP, "start-ip", "", "the start IPv4 string of the vlan's free DHCP range")
		c.Flags.StringVar(&c.freeEndIP, "end-ip", "", "the end IPv4 string of the vlan's free DHCP range")
		c.Flags.StringVar(&c.tags, "tags", "", "comma separated tags. You can only append/add new tags here.")
		return c
	},
}

AddVlanCmd add a vlan to the system.

View Source
var DeleteVlanCmd = &subcommands.Command{
	UsageLine: "vlan",
	ShortDesc: "Delete vlan",
	LongDesc: `Delete vlan.

Example:
shivas delete vlan {vlan Name}
Deletes the given vlan configuration.`,
	CommandRun: func() subcommands.CommandRun {
		c := &deleteVlan{}
		c.authFlags.Register(&c.Flags, site.DefaultAuthOptions)
		c.envFlags.Register(&c.Flags)
		return c
	},
}

DeleteVlanCmd delete Chromevlan by given name.

View Source
var GetVlanCmd = &subcommands.Command{
	UsageLine: "vlan ...",
	ShortDesc: "Get vlan details by filters",
	LongDesc: `Get vlan details by filters.

Example:

shivas get vlan name1 name2

shivas get vlan

shivas get vlan -state serving

Gets the vlan and prints the output in the user-specified format.`,
	CommandRun: func() subcommands.CommandRun {
		c := &getVlan{}
		c.authFlags.Register(&c.Flags, site.DefaultAuthOptions)
		c.envFlags.Register(&c.Flags)
		c.commonFlags.Register(&c.Flags)
		c.outputFlags.Register(&c.Flags)

		c.Flags.IntVar(&c.pageSize, "n", 0, cmdhelp.ListPageSizeDesc)
		c.Flags.BoolVar(&c.keysOnly, "keys", false, cmdhelp.KeysOnlyText)

		c.Flags.Var(flag.StringSlice(&c.states), "state", "Name(s) of a state to filter by. Can be specified multiple times."+cmdhelp.StateFilterHelpText)
		c.Flags.Var(flag.StringSlice(&c.zones), "zone", "Name(s) of a zone to filter by. Can be specified multiple times."+cmdhelp.ZoneFilterHelpText)
		c.Flags.Var(flag.StringSlice(&c.tags), "tag", "Name(s) of a tag to filter by. Can be specified multiple times.")
		return c
	},
}

GetVlanCmd get vlan by given name.

View Source
var UpdateVlanCmd = &subcommands.Command{
	UsageLine: "vlan",
	ShortDesc: "Update vlan configuration for browser machine",
	LongDesc:  cmdhelp.UpdateVlanLongDesc,
	CommandRun: func() subcommands.CommandRun {
		c := &updateVlan{}
		c.authFlags.Register(&c.Flags, site.DefaultAuthOptions)
		c.envFlags.Register(&c.Flags)
		c.commonFlags.Register(&c.Flags)

		c.Flags.StringVar(&c.name, "name", "", "name of the vlan")
		c.Flags.StringVar(&c.description, "desc", "", "description for the vlan. "+cmdhelp.ClearFieldHelpText)
		c.Flags.StringVar(&c.state, "state", "", cmdhelp.StateHelp)
		c.Flags.StringVar(&c.zones, "zone", "", "comma separated zones, You can only append/add new zones here or clean it out."+cmdhelp.ZoneHelpText+cmdhelp.ClearFieldHelpText)
		c.Flags.StringVar(&c.reservedIPs, "reserved_ips", "", "comma separated ips. You can only append/add new ips here. "+cmdhelp.ClearFieldHelpText)
		c.Flags.StringVar(&c.freeStartIP, "start-ip", "", "the start IPv4 string of the vlan's free DHCP range. "+cmdhelp.ClearFieldHelpText)
		c.Flags.StringVar(&c.freeEndIP, "end-ip", "", "the end IPv4 string of the vlan's free DHCP range. "+cmdhelp.ClearFieldHelpText)
		c.Flags.StringVar(&c.tags, "tags", "", "comma separated tags. You can only append/add new tags here. "+cmdhelp.ClearFieldHelpText)
		return c
	},
}

UpdateVlanCmd update Vlan by given name.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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