Documentation ¶
Index ¶
- Constants
- func BoolFromEnv(envName string) bool
- func ConfigFromVault(optionalName ...string) (*pb.ElasticConfigVault, error)
- func CreateCertClient(org []string) (certificates.CertClient, error)
- func CreateNewRandomizer() (randomizer.Random, error)
- func CreateOdysseiaClient() (service.OdysseiaClient, error)
- func OdysseiaRootPath(path string) string
- func ParsedPodNameFromEnv() string
- func PlatoPath(path string) string
- func RetrieveCertPathLocally(testOverwrite bool, service string) (cert string, key string)
- func SliceFromEnv(sliceName string) []string
- func StringFromEnv(envName, defaultValue string) string
Constants ¶
View Source
const ( PLATO = "plato" ODYSSEIA_PATH = "odysseia-greek" DefaultSidecarService = "localhost:50051" DefaultKubeConfig = "/.kube/config" DefaultNamespace = "odysseia" DefaultPodname = "somepod-08595-383" DefaultSearchWord = "greek" DefaultRoleName = "solon" DefaultJobName = "demokritos" DefaultServiceAddress = "http://odysseia-greek.internal" DefaultCaValidity = "3650" DefaultCrdName = "perikles-mapping" EnvHealthCheckOverwrite = "HEALTH_CHECK_OVERWRITE" EnvPodName = "POD_NAME" EnvNamespace = "NAMESPACE" EnvIndex = "ELASTIC_ACCESS" EnvSecondaryIndex = "ELASTIC_SECONDARY_ACCESS" EnvVaultService = "VAULT_SERVICE" EnvSolonService = "SOLON_SERVICE" EnvPtolemaiosService = "PTOLEMAIOS_SERVICE" EnvHerodotosService = "HERODOTOS_SERVICE" EnvAlexandrosService = "ALEXANDROS_SERVICE" EnvSokratesService = "SOKRATES_SERVICE" EnvDionysiosService = "DIONYSIOS_SERVICE" EnvRunOnce = "RUN_ONCE" EnvTlSKey = "TLS_ENABLED" EnvKey = "ENV" EnvSearchWord = "SEARCH_WORD" EnvRole = "ELASTIC_ROLE" EnvRoles = "ELASTIC_ROLES" EnvIndexes = "ELASTIC_INDEXES" EnvRootToken = "VAULT_ROOT_TOKEN" EnvAuthMethod = "AUTH_METHOD" EnvTLSEnabled = "VAULT_TLS" EnvVaultRole = "VAULT_ROLE" EnvKubePath = "KUBE_PATH" EnvSidecarOverwrite = "SIDECAR_OVERWRITE" EnvJobName = "JOB_NAME" EnvCAValidity = "CA_VALIDITY" EnvCrdName = "CRD_NAME" EnvTLSFiles = "TLS_FILES" EnvRootTlSDir = "CERT_ROOT" AuthMethodKube = "kubernetes" AuthMethodToken = "token" DefaultRoleAnnotation = "odysseia-greek/role" DefaultAccessAnnotation = "odysseia-greek/access" DefaultTLSFileLocation = "/etc/certs" EnvTestOverWrite = "TEST_OVERWRITE" EnvChannel = "EUPALINOS_CHANNEL" EnvEupalinosService = "EUPALINOS_SERVICE" DefaultEupalinosService = "eupalinos:50051" DefaultParmenidesChannel = "parmenides" DefaultDutchChannel = "mouseion" DefaultTracingName = "agreus" HeaderKey = "aischylos" CreatorElasticRole = "creator" SeederElasticRole = "seeder" HybridElasticRole = "hybrid" ApiElasticRole = "api" AliasElasticRole = "alias" TracingElasticIndex = "tracing" )
Variables ¶
This section is empty.
Functions ¶
func BoolFromEnv ¶
func ConfigFromVault ¶
func ConfigFromVault(optionalName ...string) (*pb.ElasticConfigVault, error)
ConfigFromVault establishes a gRPC connection to the Ptolemaios service, checks the health status, and retrieves a secret from the service. It retries with an increasing sleep time for establishing the gRPC connection and for the health check. The maximum sleep duration for the health check is capped at 8 seconds for the last 5 attempts. If successful, it returns the retrieved secret and nil error. If the maximum number of attempts is reached without success, it returns an error indicating the failure.
func CreateCertClient ¶
func CreateCertClient(org []string) (certificates.CertClient, error)
func CreateNewRandomizer ¶
func CreateNewRandomizer() (randomizer.Random, error)
func CreateOdysseiaClient ¶
func CreateOdysseiaClient() (service.OdysseiaClient, error)
func OdysseiaRootPath ¶
func ParsedPodNameFromEnv ¶
func ParsedPodNameFromEnv() string
func RetrieveCertPathLocally ¶
func SliceFromEnv ¶
func StringFromEnv ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.