frontend groundwork
Some checks failed
Build and push docker image / Build (pull_request) Successful in 1m32s
Build and release APK / Build APK (pull_request) Failing after 2m44s

This commit is contained in:
2024-08-01 14:39:15 +02:00
parent 07dde5ab58
commit f62fa43653
13 changed files with 399 additions and 163 deletions

View File

@@ -13,6 +13,6 @@ EXPOSE 8000
# Set environment variables used by the deployment. These can be overridden by the user using this image.
ENV NUM_WORKERS=1
ENV OSM_CACHE_DIR=/cache
ENV MEMCACHED_HOST=none
ENV MEMCACHED_HOST_PATH=none
CMD fastapi run src/main.py --port 8000 --workers $NUM_WORKERS

View File

@@ -26,6 +26,6 @@ logging.config.dictConfig(config)
if os.getenv('DEBUG', False):
logging.getLogger().setLevel(logging.DEBUG)
MEMCACHE_HOST = os.getenv('MEMCACHE_HOST', None)
if MEMCACHE_HOST == "none":
MEMCACHE_HOST = None
MEMCACHED_HOST_PATH = os.getenv('MEMCACHED_HOST_PATH', None)
if MEMCACHED_HOST_PATH == "none":
MEMCACHED_HOST_PATH = None

View File

@@ -12,7 +12,7 @@ class DummyClient:
return self._data[key]
if constants.MEMCACHE_HOST is None:
if constants.MEMCACHED_HOST is None:
client = DummyClient()
else:
client = Client(constants.MEMCACHE_HOST, timeout=1)
client = Client(constants.MEMCACHED_HOST_PATH, timeout=1)