mirror of
https://github.com/sstent/foodplanner.git
synced 2026-01-25 11:11:36 +00:00
sync - added week menus
This commit is contained in:
@@ -52,12 +52,6 @@ job "foodplanner" {
|
||||
config {
|
||||
image = "ghcr.io/sstent/foodplanner:main"
|
||||
ports = ["http"]
|
||||
|
||||
# Mount the SQLite database file to persist data
|
||||
# Adjust the source path as needed for your environment
|
||||
volumes = [
|
||||
"/alloc/tmp/meal_planner.db:/app/meal_planner.db"
|
||||
]
|
||||
}
|
||||
|
||||
resources {
|
||||
|
||||
2
main.py
2
main.py
@@ -18,7 +18,7 @@ import requests
|
||||
from fastapi import File, UploadFile
|
||||
|
||||
# Database setup - Use SQLite for easier setup
|
||||
DATABASE_URL = "sqlite:///./meal_planner.db"
|
||||
DATABASE_URL = "sqlite:///data/meal_planner.db"
|
||||
# For production, use PostgreSQL: DATABASE_URL = "postgresql://username:password@localhost/meal_planner"
|
||||
|
||||
engine = create_engine(DATABASE_URL, connect_args={"check_same_thread": False} if "sqlite" in DATABASE_URL else {})
|
||||
|
||||
Reference in New Issue
Block a user