File tree 3 files changed +9
-9
lines changed
3 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ POSTGRES_HOST=resources-postgres
4
4
POSTGRES_DB = resources-psql
5
5
FLASK_ENV = development
6
6
FLASK_DEBUG = 1
7
- APPLICATION_ID = search_id
8
- API_KEY = search_key
7
+ ALGOLIA_APP_ID = search_id
8
+ ALGOLIA_API_KEY = search_key
9
9
INDEX_NAME = resources_api
10
10
INDEX_SEARCHED = FALSE
Original file line number Diff line number Diff line change 15
15
from app .healthcheck import add_health_check # noqa
16
16
17
17
# Connect to Agolia
18
- search_client = SearchClient .create (Config .APPLICATION_ID , Config .API_KEY )
18
+ search_client = SearchClient .create (Config .ALGOLIA_APP_ID , Config .ALGOLIA_API_KEY )
19
19
index = search_client .init_index (Config .INDEX_NAME )
20
20
21
21
Original file line number Diff line number Diff line change @@ -32,10 +32,10 @@ def get_sys_exec_root_or_drive():
32
32
if not pg_host :
33
33
raise KeyError ("Application requires 'POSTGRES_HOST' to run" )
34
34
35
- application_id = os .environ .get ('APPLICATION_ID ' )
36
- api_key = os .environ .get ('API_KEY ' )
37
- if not all ([application_id , api_key ]):
38
- print ("Application requires SEARCH_USER' and 'SEARCH_KEY ' for search" )
35
+ algolia_app_id = os .environ .get ('ALGOLIA_APP_ID ' )
36
+ algolia_api_key = os .environ .get ('ALGOLIA_API_KEY ' )
37
+ if not all ([algolia_app_id , algolia_api_key ]):
38
+ print ("Application requires 'ALGOLIA_APP_ID' and 'ALGOLIA_API_KEY ' for search" )
39
39
40
40
index_name = os .environ .get ("INDEX_NAME" )
41
41
@@ -45,8 +45,8 @@ class Config:
45
45
46
46
SQLALCHEMY_DATABASE_URI = f"postgresql://{ pg_user } :{ pg_pw } @{ pg_host } :5432/{ pg_db } "
47
47
48
- APPLICATION_ID = application_id
49
- API_KEY = api_key
48
+ ALGOLIA_APP_ID = algolia_app_id
49
+ ALGOLIA_API_KEY = algolia_api_key
50
50
INDEX_NAME = index_name
51
51
52
52
# Can pass in changes to defaults, such as PaginatorConfig(per_page=40)
You can’t perform that action at this time.
0 commit comments