nginx

package
v0.0.114 Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2020 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Dependency is the key used in the build plan by this buildpack
	Dependency = "nginx"
	Mainline   = "mainline"
	Stable     = "stable"
)

Variables

This section is empty.

Functions

func CheckPortExistsInConf

func CheckPortExistsInConf(nginxConfPath string, log logger.Logger) error

CheckPortExistsInConf will validate that a `listen {{port}}` directive has been added by the user, if not it prints a warning to the user

func LoadMainlineVersion

func LoadMainlineVersion(metadata buildpack.Metadata) string

LoadMainlineVersion out of buildpack.toml

func LoadStableVersion

func LoadStableVersion(metadata buildpack.Metadata) string

LoadStableVersion out of buildpack.toml

Types

type BuildpackYAML

type BuildpackYAML struct {
	Config Config `yaml:"nginx"`
}

BuildpackYAML defines configuration options allowed to end users

func LoadBuildpackYAML

func LoadBuildpackYAML(appRoot string) (BuildpackYAML, error)

LoadBuildpackYAML reads `buildpack.yml` and NGINX specific config options in it

type Config

type Config struct {
	Version string `yaml:"version"`
}

Config is used by BuildpackYAML and defines NGINX specific config options available to users

type Contributor

type Contributor struct {
	// contains filtered or unexported fields
}

Contributor is responsible for deciding what this buildpack will contribute during build

func NewContributor

func NewContributor(context build.Build) (c Contributor, willContribute bool, err error)

NewContributor will create a new Contributor object

func (Contributor) Contribute

func (c Contributor) Contribute() error

Contribute will install NGINX, configure required env variables & set a start command

func (Contributor) Setup added in v0.0.71

func (c Contributor) Setup() error

Jump to

Keyboard shortcuts

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