Corrected storage issue by adding a docker volume for file persistance

This commit is contained in:
Christbru 2025-10-19 06:18:36 -05:00
commit 38532056e5
4 changed files with 30 additions and 5 deletions

View file

@ -6,7 +6,7 @@ use std::path::{Path, PathBuf};
pub fn storage_dir() -> PathBuf {
std::env::var("ASTRA_STORAGE")
.map(PathBuf::from)
.unwrap_or_else(|_| std::env::current_dir().unwrap().join("storage"))
.unwrap_or_else(|_| PathBuf::from("/app/storage"))
}
pub fn ensure_storage_dir() -> Result<()> {