Documentation
¶
Overview ¶
Package env provides runtime, server level setup and configuration
Package env provides runtime, server level setup and configuration ¶
Package env provides runtime, server level setup and configuration
Index ¶
Constants ¶
View Source
const ( // SiteModeNormal serves app SiteModeNormal = "" // SiteModeOffline serves offline.html SiteModeOffline = "1" // SiteModeSetup tells Ember to serve setup route SiteModeSetup = "2" // SiteModeBadDB redirects to db-error.html page SiteModeBadDB = "3" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DbVariant ¶ added in v1.51.0
type DbVariant string
DbVariant details SQL database variant
const ( // DbVariantMySQL is MySQL DbVariantMySQL DbVariant = "MySQL" // DBVariantPercona is Percona DBVariantPercona DbVariant = "Percona" // DBVariantMariaDB is MariaDB DBVariantMariaDB DbVariant = "MariaDB" // DBVariantMSSQL is Microsoft SQL Server DBVariantMSSQL DbVariant = "MSSQL" // DBVariantPostgreSQL is PostgreSQL DBVariantPostgreSQL DbVariant = "PostgreSQL" )
type Flags ¶
type Flags struct {
DBConn string // database connection string
Salt string // the salt string used to encode JWT tokens
DBType string // (optional) database type
SSLCertFile string // (optional) name of SSL certificate PEM file
SSLKeyFile string // (optional) name of SSL key PEM file
HTTPPort string // (optional) HTTP or HTTPS port
ForceHTTPPort2SSL string // (optional) HTTP that should be redirected to HTTPS
SiteMode string // (optional) if 1 then serve offline web page
}
Flags provides access to environment and command line switches for this program.
func ParseFlags ¶
func ParseFlags() (f Flags)
ParseFlags loads command line and OS environment variables required by the program to function.
func (*Flags) SSLEnabled ¶
SSLEnabled returns true if both cert and key were provided at runtime.
type License ¶
type License struct {
Name string `json:"name"`
Email string `json:"email"`
Edition string `json:"edition"`
Start time.Time `json:"start"`
End time.Time `json:"end"`
Seats int `json:"seats"`
Trial bool `json:"trial"`
Valid bool
}
License holds details of product license.
type LicenseData ¶
LicenseData holds encrypted data and is unpacked into License.
type Logger ¶
type Logger interface {
Info(message string)
Trace(message string)
Error(message string, err error)
}
Logger provides the interface for Documize compatible loggers.
Click to show internal directories.
Click to hide internal directories.