diff --git a/core/settings.py b/core/settings.py index 22e2d23..0edc7b8 100644 --- a/core/settings.py +++ b/core/settings.py @@ -34,10 +34,16 @@ "corsheaders.middleware.CorsMiddleware", ] -DATABASES = {"default": { - "ENGINE": "django.db.backends.sqlite3", - "NAME": os.path.join(BASE_DIR, "data", "db.sqlite3") -}} +if DEBUG: + DATABASES = {"default": { + "ENGINE": "django.db.backends.sqlite3", + "NAME": os.path.join(BASE_DIR, "data", "db.sqlite3") + }} +else: + DATABASES = {"default": { + "ENGINE": "django.db.backends.sqlite3", + "NAME": os.path.join(BASE_DIR, "..", "data", "db.sqlite3") + }} STATIC_URL = "/static/" STATIC_ROOT = os.path.abspath(f"{BASE_DIR}/../static") diff --git a/upload-data.sh b/upload-data.sh index f87584a..02576ee 100755 --- a/upload-data.sh +++ b/upload-data.sh @@ -1,5 +1,5 @@ host="api.zincbind.net" -scp data/db.sqlite3 $host:~/$host/source/data/ +scp data/db.sqlite3 $host:~/$host/data/ -scp data/chains.fasta* $host:~/$host/source/data/ \ No newline at end of file +scp data/chains.fasta* $host:~/$host/data/ \ No newline at end of file