define database file in config.py

This commit is contained in:
Nick Sweeting 2019-04-11 03:40:37 -04:00
parent b69f26297b
commit bcfe17bc87
2 changed files with 4 additions and 7 deletions

View file

@ -1,10 +1,8 @@
import os
__package__ = 'archivebox.core'
from legacy.config import (
REPO_DIR,
OUTPUT_DIR,
from ..legacy.config import (
TEMPLATES_DIR,
DATABASE_DIR,
DATABASE_FILE,
)
@ -52,8 +50,6 @@ TEMPLATES = [
WSGI_APPLICATION = 'core.wsgi.application'
DATABASE_FILE = os.path.join(DATABASE_DIR, 'database.sqlite3')
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',

View file

@ -91,6 +91,7 @@ DATABASE_DIR_NAME = 'database'
ARCHIVE_DIR = os.path.join(OUTPUT_DIR, ARCHIVE_DIR_NAME)
SOURCES_DIR = os.path.join(OUTPUT_DIR, SOURCES_DIR_NAME)
DATABASE_DIR = os.path.join(OUTPUT_DIR, DATABASE_DIR_NAME)
DATABASE_FILE = os.path.join(DATABASE_DIR, 'database.sqlite3')
PYTHON_DIR = os.path.join(REPO_DIR, 'archivebox')
LEGACY_DIR = os.path.join(PYTHON_DIR, 'legacy')