siteaddr

package
v1.166.4 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2026 License: Apache-2.0 Imports: 4 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package siteaddr is every hostname the deployment answers on for a site or an application, as the system administrator's ingress rules need them: each site's addresses on the pages domain and every domain added, with a site domain's role (#2687). GET /api/v1/admin/sites/domains answers it.

Index

Constants

View Source
const (
	KindSite        = "site_address"
	KindDomain      = "domain"
	KindApplication = "application"
)

The kinds of address.

View Source
const TimeLayout = "2006-01-02T15:04:05Z"

TimeLayout is how an address's creation time is written.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddressList

type AddressList struct {
	Addresses []DeploymentAddress `json:"addresses"`
}

AddressList is every site address and domain on the deployment.

func List

func List(domains []site.Domain, sites []site.Site, pagesDomain string) AddressList

List is every domain and, with a pages domain, every site's addresses on it, in hostname order.

type DeploymentAddress

type DeploymentAddress struct {
	Hostname    string `json:"hostname" example:"marketing.pages.example.net"`
	Kind        string `json:"kind" example:"site_address"`
	Site        string `json:"site,omitempty" example:"marketing"`
	Environment string `json:"environment,omitempty" example:"default"`
	Application string `json:"application,omitempty"`
	// Primary, Mode and RedirectsTo are a site domain's role (#2687): a
	// redirect domain needs the same ingress as any other, and the gateway
	// answers the redirect. Absent on a pages address and an application's
	// domain.
	Primary     bool   `json:"primary,omitempty"`
	Mode        string `json:"mode,omitempty" enums:"serve,redirect"`
	RedirectsTo string `json:"redirects_to,omitempty"`
	CreatedBy   string `json:"created_by"`
	CreatedAt   string `json:"created_at"`
}

DeploymentAddress is one hostname the deployment answers on for a site or an application. Each needs an ingress rule, added by a system administrator.

Jump to

Keyboard shortcuts

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