Package wisp.deployment

Types

Link copied to clipboard
data class Deployment(name: String, isProduction: Boolean, isStaging: Boolean, isTest: Boolean, isLocalDevelopment: Boolean)

Deployment describes the context in which the application is running

Link copied to clipboard
interface DeploymentLocation

For information about the deployment location.

Link copied to clipboard
class EnvironmentVariableDeploymentLocation(environmentVariableName: String, environmentVariableLoader: EnvironmentVariableLoader) : DeploymentLocation

Provides a deployment location id from the environment variable value.

Link copied to clipboard
interface EnvironmentVariableLoader

Loads an environment variable value.

Link copied to clipboard
class RealEnvironmentVariableLoader : EnvironmentVariableLoader

Functions

Link copied to clipboard
fun getDeploymentFromEnvironmentVariable(defaultDeployment: Deployment = DEVELOPMENT, environmentVariableLoader: EnvironmentVariableLoader = EnvironmentVariableLoader.real): Deployment

Determines a Deployment based on the value within the ENVIRONMENT variable, defaulting to local development if not set (i.e. isLocalDevelopment == true)

Properties

Link copied to clipboard
val deployments: Map<String, Deployment>
Link copied to clipboard
val DEVELOPMENT: Deployment
Link copied to clipboard
val PRODUCTION: Deployment
Link copied to clipboard
val STAGING: Deployment
Link copied to clipboard
val TESTING: Deployment