constants

package
v0.0.0-...-9994f1b Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Default VM Leaser parameters for dev service
	DevDefaultParams = DefaultLeaseParams{

		DefaultDiskSize: 20,

		DefaultMachineType: "e2-medium",

		DefaultNetwork: "global/networks/default",

		DefaultProject: "chrome-fleet-vm-leaser-dev",

		DefaultRegion: "us-central1-a",

		DefaultLeaseDuration: 600,
	}

	// Default VM Leaser parameters for prod service
	ProdDefaultParams = DefaultLeaseParams{

		DefaultDiskSize: 20,

		DefaultMachineType: "n2-standard-4",

		DefaultNetwork: "global/networks/default",

		DefaultProject: "chrome-fleet-vm-leaser-prod",

		DefaultRegion: "us-central1-a",

		DefaultLeaseDuration: 600,
	}
)
View Source
var (
	UsCentral1 = []string{
		"us-central1-a",
		"us-central1-b",
		"us-central1-c",
		"us-central1-f",
	}

	UsEast1 = []string{
		"us-east1-b",
		"us-east1-c",
		"us-east1-d",
	}

	UsEast4 = []string{
		"us-east4-a",
		"us-east4-b",
		"us-east4-c",
	}

	UsWest1 = []string{
		"us-west1-a",
		"us-west1-b",
		"us-west1-c",
	}
)

A list of GCP zones for VM Leaser service to manage VMs in

View Source
var (
	AllQuotaZones = map[string][]string{
		"us-central1": UsCentral1,
		"us-east1":    UsEast1,
		"us-east4":    UsEast4,
		"us-west1":    UsWest1,
	}

	ChromeOSZones = [][]string{
		AllQuotaZones["us-central1"],
		AllQuotaZones["us-east1"],
		AllQuotaZones["us-east4"],
		AllQuotaZones["us-west1"],
	}
)

Different zonal configurations for different products

AllQuotaZones is the list of zones where quota for VMs has been given. All other zonal configurations are defined using AllQuotaZones. Each key in AllQuotaZones represents a main zone and is defined in the GCP region format.

Functions

This section is empty.

Types

type DefaultLeaseParams

type DefaultLeaseParams struct {
	// Default disk size to use for VM creation
	DefaultDiskSize int64
	// Default machine type to use for VM creation
	DefaultMachineType string
	// Default network to use for VM creation
	DefaultNetwork string
	// Default GCP Project to use
	DefaultProject string
	// Default region (zone) to use
	DefaultRegion string
	// Default duration of lease (in minutes)
	DefaultLeaseDuration int64
}

A list of default parameters for VM Leaser

func GetDefaultParams

func GetDefaultParams(env string) DefaultLeaseParams

GetDefaultParams returns the default params of a prod/dev environment

Jump to

Keyboard shortcuts

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