add local envs
This commit is contained in:
@@ -7,10 +7,9 @@ COURSE_TABLE: str = os.getenv('COURSE_TABLE') # type: ignore
|
||||
|
||||
ELASTIC_CLOUD_ID = os.getenv('ELASTIC_CLOUD_ID')
|
||||
ELASTIC_AUTH_PASS = os.getenv('ELASTIC_AUTH_PASS')
|
||||
ELASTIC_HOSTS = os.getenv('ELASTIC_HOSTS', None)
|
||||
|
||||
if ELASTIC_HOSTS:
|
||||
ELASTIC_CONN = {'hosts': ELASTIC_HOSTS}
|
||||
if {'AWS_SAM_LOCAL', 'ELASTIC_HOSTS'}.intersection(os.environ):
|
||||
ELASTIC_CONN = {'hosts': 'http://host.docker.internal:9200'}
|
||||
else:
|
||||
ELASTIC_CONN = {
|
||||
'cloud_id': ELASTIC_CLOUD_ID,
|
||||
|
||||
Reference in New Issue
Block a user