dns

package
v0.0.0-...-df16b1f Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2025 License: BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Overview

Copyright 2023 The Chromium Authors Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.

Copyright 2023 The Chromium Authors Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.

Copyright 2023 The Chromium Authors Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.

Index

Constants

This section is empty.

Variables

View Source
var DeleteDNSCmd = &subcommands.Command{
	UsageLine: "dns -host <hostname>",
	ShortDesc: "delete DNS entry in local satlab network",
	LongDesc:  "Delete DNS entry in local satlab network",
	CommandRun: func() subcommands.CommandRun {
		c := &deleteDNSRun{}
		c.Flags.StringVar(&c.host, "host", "", "hostname to delete")
		return c
	},
}

DeleteDNSCmd is the command to delete a hostname from the hostsfile of the DNS container

View Source
var GetDNSCmd = &subcommands.Command{
	UsageLine: "dns",
	ShortDesc: "get DNS entries for local satlab network",
	LongDesc:  "Get DNS entries for local satlab network",
	CommandRun: func() subcommands.CommandRun {
		c := &getDNSRun{}
		return c
	},
}

GetDNSCmd is the command to print the current DNS entries for local satlab network

View Source
var UpdateDNSCmd = &subcommands.Command{
	UsageLine: "dns -host <hostname> -address <address>",
	ShortDesc: "upsert DNS entry in local satlab network",
	LongDesc:  "Upsert DNS entry in local satlab network",
	CommandRun: func() subcommands.CommandRun {
		c := &updateDNSRun{}
		c.Flags.StringVar(&c.host, "host", "", "hostname to update")
		c.Flags.StringVar(&c.address, "address", "", "address to associate with hostname")
		return c
	},
}

UpdateDNSCmd is the command to upsert a hostname-ip pairing in /etc/dut_hosts/hosts used in DNS container

Functions

This section is empty.

Types

type DockerHostBoxIdentifierGetter

type DockerHostBoxIdentifierGetter func(context.Context, executor.IExecCommander) (string, error)

DockerHostBoxIdentifierGetter is a function type fulfilled by satlabcommands.GetDockerHostBoxIdentifier we do this because the function assumes we are in a real Satlab env and we can't unit test using this func

type HostfileUpdater

type HostfileUpdater func(ctx context.Context, host string, addr string) (string, error)

HostfileUpdater is a function type fulfilled by UpdateRecord it should take care of the e2e flow of updating a record and applying those changes any implementation should be atomic

Jump to

Keyboard shortcuts

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