config

package
v2.4.7 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2022 License: Apache-2.0 Imports: 22 Imported by: 1

Documentation

Index

Constants

View Source
const (
	IDENTITY_STORE_HOST          = "localhost:20000"
	IDENTITY_STORE_DB            = "ownersDevices"
	GW_HOST                      = "localhost:20002"
	RESOURCE_AGGREGATE_HOST      = "localhost:20003"
	RESOURCE_DIRECTORY_HOST      = "localhost:20004"
	CERTIFICATE_AUTHORITY_HOST   = "localhost:20011"
	GRPC_HOST                    = "localhost:20005"
	C2C_CONNECTOR_HOST           = "localhost:20006"
	C2C_CONNECTOR_DB             = "cloud2cloudConnector"
	C2C_GW_HOST                  = "localhost:20007"
	C2C_GW_DB                    = "cloud2cloudGateway"
	OAUTH_SERVER_HOST            = "localhost:20009"
	TEST_TIMEOUT                 = time.Second * 30
	OAUTH_MANAGER_CLIENT_ID      = "test"
	OAUTH_MANAGER_AUDIENCE       = "localhost"
	HTTP_GW_HOST                 = "localhost:20010"
	DEVICE_PROVIDER              = "plgd"
	OPENTELEMETRY_COLLECTOR_HOST = "localhost:55690"
)
View Source
const JWTSecret = "secret"

Variables

View Source
var (
	CA_POOL     = os.Getenv("LISTEN_FILE_CA_POOL")
	KEY_FILE    = os.Getenv("LISTEN_FILE_CERT_DIR_PATH") + "/" + os.Getenv("LISTEN_FILE_CERT_KEY_NAME")
	CERT_FILE   = os.Getenv("LISTEN_FILE_CERT_DIR_PATH") + "/" + os.Getenv("LISTEN_FILE_CERT_NAME")
	MONGODB_URI = "mongodb://localhost:27017"
	NATS_URL    = "nats://localhost:4222"
	OWNER_CLAIM = "sub"
)
View Source
var (
	OAUTH_MANAGER_ENDPOINT_AUTHURL  = http.HTTPS_SCHEME + OAUTH_SERVER_HOST + uri.Authorize
	OAUTH_MANAGER_ENDPOINT_TOKENURL = http.HTTPS_SCHEME + OAUTH_SERVER_HOST + uri.Token
	C2C_CONNECTOR_EVENTS_URL        = http.HTTPS_SCHEME + C2C_CONNECTOR_HOST + c2curi.Events
	C2C_CONNECTOR_OAUTH_CALLBACK    = http.HTTPS_SCHEME + C2C_CONNECTOR_HOST + c2curi.OAuthCallback
)

Functions

func CreateJwtToken

func CreateJwtToken(t *testing.T, claims jwt.MapClaims) string

func HubID

func HubID() string

func MakeAuthURL

func MakeAuthURL() string

func MakeAuthorizationConfig

func MakeAuthorizationConfig() validator.Config

func MakeDeviceAuthorization

func MakeDeviceAuthorization() oauth2.Config

func MakeEventsStoreMongoDBConfig

func MakeEventsStoreMongoDBConfig() mongodb.Config

func MakeGrpcClientConfig

func MakeGrpcClientConfig(address string) grpcClient.Config

func MakeGrpcServerConfig

func MakeGrpcServerConfig(address string) grpcServer.Config

func MakeHttpClientConfig

func MakeHttpClientConfig() httpClient.Config

func MakeHttpServerConfig added in v2.4.6

func MakeHttpServerConfig() httpServer.Config

func MakeListenerConfig

func MakeListenerConfig(address string) listener.Config

func MakeOpenTelemetryCollectorClient added in v2.4.0

func MakeOpenTelemetryCollectorClient() otelClient.Config

func MakePublisherConfig

func MakePublisherConfig() natsClient.ConfigPublisher

func MakeSubscriberConfig

func MakeSubscriberConfig() natsClient.Config

func MakeTLSClientConfig

func MakeTLSClientConfig() client.Config

func MakeTLSServerConfig

func MakeTLSServerConfig() server.Config

Types

This section is empty.

Jump to

Keyboard shortcuts

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