Security improvements and architecture cleanup
- Remove hardcoded production paths for open source security - Require INPUT_DIR and OUTPUT_DIR environment variables - Remove organizational references from examples - Clean up old deployment code with personal info - Improve maintainability with proper env var validation
This commit is contained in:
parent
8c84b69028
commit
3cf60dbad1
|
@ -3,8 +3,8 @@ INPUT_DIR=/home/user/livestreams
|
|||
OUTPUT_DIR=/media/archive/livestreams
|
||||
|
||||
# Program naming
|
||||
DIVINE_WORSHIP_NAME=Divine Worship Service - RTSDA
|
||||
AFTERNOON_PROGRAM_NAME=Afternoon Program - RTSDA
|
||||
DIVINE_WORSHIP_NAME=Divine Worship Service
|
||||
AFTERNOON_PROGRAM_NAME=Afternoon Program
|
||||
|
||||
# FFmpeg Configuration
|
||||
FFMPEG_BINARY=ffmpeg
|
||||
|
|
1
Cargo.lock
generated
1
Cargo.lock
generated
|
@ -811,6 +811,7 @@ checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65"
|
|||
[[package]]
|
||||
name = "video_processing"
|
||||
version = "0.1.0"
|
||||
source = "git+https://git.rockvilletollandsda.church/RTSDA/video-processing-support.git?branch=main#734c7296641ed1954b3054679e04f2a286d7f321"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"async-trait",
|
||||
|
|
10
src/main.rs
10
src/main.rs
|
@ -24,16 +24,10 @@ async fn main() -> Result<()> {
|
|||
info!("Starting Livestream Archiver v0.1.0");
|
||||
|
||||
let watch_path = PathBuf::from(
|
||||
env::var("INPUT_DIR").unwrap_or_else(|_| {
|
||||
warn!("INPUT_DIR not set, using production default: /home/rockvilleav/.rtsda/livestreams");
|
||||
"/home/rockvilleav/.rtsda/livestreams".to_string()
|
||||
})
|
||||
env::var("INPUT_DIR").expect("INPUT_DIR environment variable must be set")
|
||||
);
|
||||
let output_path = PathBuf::from(
|
||||
env::var("OUTPUT_DIR").unwrap_or_else(|_| {
|
||||
warn!("OUTPUT_DIR not set, using production default: /media/archive/jellyfin/livestreams");
|
||||
"/media/archive/jellyfin/livestreams".to_string()
|
||||
})
|
||||
env::var("OUTPUT_DIR").expect("OUTPUT_DIR environment variable must be set")
|
||||
);
|
||||
|
||||
// Ensure directories exist
|
||||
|
|
Loading…
Reference in a new issue