func Debug() bool {
	env := os.Environ()
	for _, kv := range env {
		if kv == "BTRFAAS_DEBUG=true" {
			return true
		}
	}
	return false
}
Debug returns true if the environment variable BTRFAAS_DEBUG is set to "true"
this can be evaluated by Platform implementations to help debugging
in fact currently this is only evaluated by the docker platform and turns off auto-deletion of failed functions.
This is useful if your function service will not even start and you need to look at the logs of your failed container.
package deployment
import (
	"context"
	"os"
	"time"
)
type Platform interface {
	PrepareEnvironment(ctx context.Context, options *PrepareEnvironmentOptions) error
	TeardownEnvironment(ctx context.Context, options *TeardownEnvironmentOptions) error
	ServicePlatform
	SecretPlatform
}
type ServicePlatform interface {
	DeployService(ctx context.Context, options *DeployServiceOptions) error
	UndeployService(ctx context.Context, options *UndeployServiceOptions) error
	ListServices(ctx context.Context, options *ListServicesOptions) ([]*ServiceInfo, error)
	ScaleService(ctx context.Context, options *ScaleServiceOptions) error
}
type SecretPlatform interface {
	DeploySecret(ctx context.Context, options *DeploySecretOptions) error
	UndeploySecret(ctx context.Context, options *UndeploySecretOptions) error
	GetSecret(ctx context.Context, options *GetSecretOptions) ([]byte, error)
	ListSecrets(ctx context.Context, options *ListSecretsOptions) ([]*SecretInfo, error)
}
type PrepareEnvironmentOptions struct {
	ID string
}
type TeardownEnvironmentOptions struct {
	ID string
}
type DeployServiceOptions struct {
	EnvironmentID string
	ID            string
	Image         string
	Labels        LabelSet
	Cmd           []string
	Ports         []*PortConfig
	Env           LabelSet  
	Secrets       LabelSet  
	Volumes       []*VolumeConfig
}
type VolumeConfig struct {
	Type   string
	Source string
	Target string
}
type PortConfig struct {
	Type      string
	Container uint16
	Host      uint16
}
type UndeployServiceOptions struct {
	EnvironmentID string
	ID            string
}
type ListServicesOptions struct {
	EnvironmentID string
	Labels        LabelSet
}
type ServiceInfo struct {
	ID        string
	Image     string
	Labels    LabelSet
	Cmd       []string
	Env       LabelSet  
	Secrets   LabelSet  
	CreatedAt time.Time
	Endpoint  string
	Scale     uint64
}
type DeploySecretOptions struct {
	EnvironmentID string
	ID            string
	Labels        LabelSet
	Value         []byte
}
type UndeploySecretOptions struct {
	EnvironmentID string
	ID            string
}
type ListSecretsOptions struct {
	EnvironmentID string
	Labels        LabelSet
}
type GetSecretOptions struct {
	EnvironmentID string
	ID            string
}
type SecretInfo struct {
	ID     string
	Labels LabelSet
}
type LabelSet map[string]string
type ScaleServiceOptions struct {
	EnvironmentID string
	ID            string
	Scale         uint64
}