config

package
v0.0.1-initial.0 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ConfigDefaultJSON = []byte(`
{
	"APPLICATION_NAME": "in-environment",
	"APPLICATION_ENVIRONMENT": "in-environment",
	"PRETTY_LOG": false,
	"LOG_LEVEL": "info",
	"PORT": 50051,
	"REST_PORT": 50052,
	"OAUTH2_PORT": 50053,
	"CUSTOM_STRING": "some default value",
	"SOME_SECRET": "password",
	"GRPC_GATEWAY_ENABLED": true,
	"JWT_VALIDATORS": {},
	"DD_PROFILER_CONFIG": {
		"ENABLED": false,
		"SERVICE_NAME": "in-environment",
		"APPLICATION_ENVIRONMENT": "in-environment",
		"VERSION": "1.0.0"
	},
	"KAFKA_CONFIG": {
		"SEEDS": ["localhost:9093"],
		"GROUP": "$Default",
		"TOPIC": "cloudevents-core"
	}

  }
`)

ConfigDefaultJSON default json

Functions

This section is empty.

Types

type Config

type Config struct {
	fluffycore_contracts_config.CoreConfig `mapstructure:",squash"`
	CustomString                           string                                  `json:"CUSTOM_STRING" mapstructure:"CUSTOM_STRING"`
	SomeSecret                             string                                  `json:"SOME_SECRET" mapstructure:"SOME_SECRET" redact:"true"`
	OAuth2Port                             int                                     `json:"oauth2Port"  mapstructure:"OAUTH2_PORT"`
	JWTValidators                          JWTValidators                           `json:"jwtValidators" mapstructure:"JWT_VALIDATORS"`
	DDProfilerConfig                       *fluffycore_contracts_ddprofiler.Config `json:"ddProfilerConfig" mapstructure:"DD_PROFILER_CONFIG"`
	KafkaConfig                            KafkaConfig                             `json:"kafkaConfig" mapstructure:"KAFKA_CONFIG"`
}

type JWTValidators

type JWTValidators struct {
	Issuers  []string `json:"issuers" mapstructure:"ISSUERS"`
	JWKSURLS []string `json:"jwksUrls" mapstructure:"JWKS_URLS"`
}

type KafkaConfig

type KafkaConfig struct {
	Seeds []string `json:"seeds" mapstructure:"SEEDS"`
	Group string   `json:"group" mapstructure:"GROUP"`
	Topic string   `json:"topic" mapstructure:"TOPIC"`
}

Jump to

Keyboard shortcuts

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