customization

package module
v0.0.0-...-5b0ec2e Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2024 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Overview

Package customization contains the structure for the customization file to configure the OTS web- and command-line interface

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Customize

type Customize struct {
	AppIcon              string `json:"appIcon,omitempty" yaml:"appIcon"`
	AppTitle             string `json:"appTitle,omitempty" yaml:"appTitle"`
	DisableAppTitle      bool   `json:"disableAppTitle,omitempty" yaml:"disableAppTitle"`
	DisablePoweredBy     bool   `json:"disablePoweredBy,omitempty" yaml:"disablePoweredBy"`
	DisableQRSupport     bool   `json:"disableQRSupport,omitempty" yaml:"disableQRSupport"`
	DisableThemeSwitcher bool   `json:"disableThemeSwitcher,omitempty" yaml:"disableThemeSwitcher"`

	DisableExpiryOverride bool    `json:"disableExpiryOverride,omitempty" yaml:"disableExpiryOverride"`
	ExpiryChoices         []int64 `json:"expiryChoices,omitempty" yaml:"expiryChoices"`

	AcceptedFileTypes      string `json:"acceptedFileTypes" yaml:"acceptedFileTypes"`
	DisableFileAttachment  bool   `json:"disableFileAttachment" yaml:"disableFileAttachment"`
	MaxAttachmentSizeTotal int64  `json:"maxAttachmentSizeTotal" yaml:"maxAttachmentSizeTotal"`

	MaxSecretSize         int64    `json:"-" yaml:"maxSecretSize"`
	MetricsAllowedSubnets []string `json:"-" yaml:"metricsAllowedSubnets"`
	OverlayFSPath         string   `json:"-" yaml:"overlayFSPath"`
	UseFormalLanguage     bool     `json:"-" yaml:"useFormalLanguage"`
}

Customize holds the structure of the customization file

func Load

func Load(filename string) (cust Customize, err error)

Load retrieves the Customization file from filesystem

func (Customize) ToJSON

func (c Customize) ToJSON() (string, error)

ToJSON is a templating helper which returns the customization serialized as JSON in a string

Jump to

Keyboard shortcuts

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