Documentation
¶
Index ¶
- Variables
- type Config
- type Deploy
- type Domain
- type DomainContact
- type Domains
- type Logs
- type LogsConfig
- type Platform
- type Project
- func (p *Project) ApplyStack(region string) error
- func (p *Project) Build(hooks bool) error
- func (p *Project) CreateStack(region, version string) error
- func (p *Project) DeleteStack(region string, wait bool) error
- func (p *Project) Deploy(d Deploy) error
- func (p *Project) Init(stage string) error
- func (p *Project) PlanStack(region string) error
- func (p *Project) Prune(region, stage string, versions int) error
- func (p *Project) RunHook(name string) error
- func (p *Project) RunHooks(names ...string) error
- func (p *Project) ShowMetrics(region, stage string, start time.Time) error
- func (p *Project) ShowStack(region string) error
- func (p *Project) WithPlatform(platform Platform) *Project
- func (p *Project) Zip() (io.Reader, error)
- type Pruner
- type Runtime
- type Zipper
Constants ¶
This section is empty.
Variables ¶
var MustParseConfigString = config.MustParseConfigString
MustParseConfigString returns config from JSON string.
var ParseConfigString = config.ParseConfigString
ParseConfigString returns config from JSON string.
var ReadConfig = config.ReadConfig
ReadConfig reads the configuration from `path`.
Functions ¶
This section is empty.
Types ¶
type DomainContact ¶
type DomainContact struct { Email string FirstName string LastName string CountryCode string City string Address string OrganizationName string PhoneNumber string State string ZipCode string }
DomainContact is the domain name contact information required for registration.
type Domains ¶
type Domains interface { Availability(domain string) (*Domain, error) Suggestions(domain string) ([]*Domain, error) Purchase(domain string, contact DomainContact) error List() ([]*Domain, error) }
Domains is the interface for purchasing and managing domains names.
type LogsConfig ¶
type LogsConfig struct { // Region is the target region. Region string // Query is the filter pattern. Query string // Since is used as the starting point when filtering // historical logs, no logs before this point are returned. Since time.Time // Follow is used to stream new logs. Follow bool // Expand is used to expand logs to a verbose format. Expand bool // OutputJSON is used to output raw json. OutputJSON bool }
LogsConfig is configuration for viewing logs.
type Platform ¶
type Platform interface { // Build the project. Build() error // Deploy to the given stage, to the // region(s) configured by the user. Deploy(Deploy) error // Logs returns an interface for working // with logging data. Logs(LogsConfig) Logs // Domains returns an interface for // managing domain names. Domains() Domains // URL returns the endpoint for the given // region and stage combination, or an // empty string. URL(region, stage string) (string, error) // Exists returns true if the application has been created. Exists(region string) (bool, error) CreateStack(region, version string) error DeleteStack(region string, wait bool) error ShowStack(region string) error PlanStack(region string) error ApplyStack(region string) error ShowMetrics(region, stage string, start time.Time) error }
Platform is the interface for platform integration, defining the basic set of functionality required for Up applications.
type Project ¶
type Project struct { Platform // contains filtered or unexported fields }
Project manager.
func (*Project) ApplyStack ¶
ApplyStack implementation.
func (*Project) CreateStack ¶
CreateStack implementation.
func (*Project) DeleteStack ¶
DeleteStack implementation.
func (*Project) ShowMetrics ¶
ShowMetrics implementation.
func (*Project) WithPlatform ¶
WithPlatform to `platform`.
type Pruner ¶
Pruner is the interface used to prune old versions and the artifacts associated such as S3 zip files for Lambda.
Directories
¶
Path | Synopsis |
---|---|
cmd
|
|
Package config provides configuration structures, validation, and defaulting for up.json config.
|
Package config provides configuration structures, validation, and defaulting for up.json config. |
Package handler provides what is essentially the core of Up's reverse proxy, complete with all middleware for handling logging, redirectcs, static file serving and so on.
|
Package handler provides what is essentially the core of Up's reverse proxy, complete with all middleware for handling logging, redirectcs, static file serving and so on. |
http
|
|
cors
Package cors provides CORS support.
|
Package cors provides CORS support. |
errorpages
Package errorpages provides default and customizable error pages, via error.html, 5xx.html, or 500.html for example.
|
Package errorpages provides default and customizable error pages, via error.html, 5xx.html, or 500.html for example. |
gzip
Package gzip provides gzip compression support.
|
Package gzip provides gzip compression support. |
headers
Package headers provides header injection support.
|
Package headers provides header injection support. |
inject
Package inject provides script and style injection.
|
Package inject provides script and style injection. |
logs
Package logs provides HTTP request and response logging.
|
Package logs provides HTTP request and response logging. |
poweredby
Package poweredby provides nothing :).
|
Package poweredby provides nothing :). |
redirects
Package redirects provides redirection and URL rewriting.
|
Package redirects provides redirection and URL rewriting. |
relay
Package relay provides a reverse proxy which relays requests to your "vanilla" HTTP server, and supports crash recovery.
|
Package relay provides a reverse proxy which relays requests to your "vanilla" HTTP server, and supports crash recovery. |
robots
Package robots provides a way of dealing with robots exclusion protocol
|
Package robots provides a way of dealing with robots exclusion protocol |
static
Package static provides static file serving with HTTP cache support.
|
Package static provides static file serving with HTTP cache support. |
internal
|
|
colors
Package colors provides colors used by the CLI.
|
Package colors provides colors used by the CLI. |
errorpage
Package errorpage provides error page loading utilities.
|
Package errorpage provides error page loading utilities. |
header
Package header provides path-matched header injection rules.
|
Package header provides path-matched header injection rules. |
inject
Package inject provides script and style injection utilities.
|
Package inject provides script and style injection utilities. |
logs
Package logs provides logging utilities.
|
Package logs provides logging utilities. |
logs/parser
Package parser provides a parser for Up's log query language, abstracting away provider specifics.
|
Package parser provides a parser for Up's log query language, abstracting away provider specifics. |
logs/parser/ast
Package ast provides the log query language abstract syntax tree.
|
Package ast provides the log query language abstract syntax tree. |
logs/text
Package text implements a development-friendly textual handler.
|
Package text implements a development-friendly textual handler. |
logs/writer
Package writer provides an io.Writer for capturing process output as logs, so that stdout may become INFO, and stderr ERROR.
|
Package writer provides an io.Writer for capturing process output as logs, so that stdout may become INFO, and stderr ERROR. |
metrics
Package metrics provides higher level CloudWatch metrics operations.
|
Package metrics provides higher level CloudWatch metrics operations. |
progressreader
Package progressreader provides an io.Reader progress bar.
|
Package progressreader provides an io.Reader progress bar. |
proxy
Package proxy provides API Gateway and Lambda interoperability.
|
Package proxy provides API Gateway and Lambda interoperability. |
redirect
Package redirect provides compiling and matching redirect and rewrite rules.
|
Package redirect provides compiling and matching redirect and rewrite rules. |
setup
Package setup provides up.json initialization.
|
Package setup provides up.json initialization. |
shim
Package shim provides a shim for running arbitrary languages on Lambda.
|
Package shim provides a shim for running arbitrary languages on Lambda. |
stats
Package stats provides CLI analytics.
|
Package stats provides CLI analytics. |
userconfig
Package userconfig provides user machine-level configuration.
|
Package userconfig provides user machine-level configuration. |
util
Package util haters gonna hate.
|
Package util haters gonna hate. |
validate
Package validate provides config validation functions.
|
Package validate provides config validation functions. |
platform
|
|
aws/cost
Package cost provides utilities for calculating AWS Lambda pricing.
|
Package cost provides utilities for calculating AWS Lambda pricing. |
aws/domains
Package domains provides domain management for AWS platforms.
|
Package domains provides domain management for AWS platforms. |
aws/logs
Package logs provides log management for AWS platforms.
|
Package logs provides log management for AWS platforms. |
aws/regions
Package regions provides AWS region utilities.
|
Package regions provides AWS region utilities. |
event
Package event provides an evented mechanism for hooking into platform specifics.
|
Package event provides an evented mechanism for hooking into platform specifics. |
lambda
Package lambda implements the API Gateway & AWS Lambda platform.
|
Package lambda implements the API Gateway & AWS Lambda platform. |
lambda/stack
Package stack provides CloudFormation stack support.
|
Package stack provides CloudFormation stack support. |
discard
Package discard provides a reporter for discarding events.
|
Package discard provides a reporter for discarding events. |
plain
Package plain provides plain-text reporting for CI.
|
Package plain provides plain-text reporting for CI. |
text
Package text provides a reporter for humanized interactive events.
|
Package text provides a reporter for humanized interactive events. |