environment

package
v0.0.0-...-8cc5058 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {

	// host to start the httpserver on
	Websocket struct {
		Host string `default:"0.0.0.0:80"`
	}

	// redis server connection
	Redis struct {
		Host     string `default:"orca.redis:6379"`
		Password string `default:""`
	}

	// information about process service
	Process struct {
		Address string `default:"service.process"`
	}

	// information about image service
	Image struct {
		Address string `default:"service.image"`
	}

	// database configuration for the postgres connection
	Postgres database.Config `envconfig:"DB"`
}

Configuration holds the basic config information for the service

func LoadConfiguration

func LoadConfiguration(prefix string) (Configuration, error)

LoadConfiguration will load the basic application configuration from the specified config file

type Services

type Services struct {
	// redis database to store transactions in memory
	Redis *redis.Client

	// postgres database
	Postgres *repository.DB

	// process service to handle document
	Process process.ProcessClient

	// image service to handle images
	Image image.ImageClient
}

Services is used to provide all necessary services

Jump to

Keyboard shortcuts

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