1 use lemmy_server::{init_logging, start_lemmy_server};
2 use lemmy_utils::{error::LemmyError, settings::SETTINGS};
5 pub async fn main() -> Result<(), LemmyError> {
6 init_logging(&SETTINGS.opentelemetry_url)?;
7 #[cfg(not(feature = "embed-pictrs"))]
8 start_lemmy_server().await?;
9 #[cfg(feature = "embed-pictrs")]
11 pict_rs::ConfigSource::memory(serde_json::json!({
13 "address": "127.0.0.1:8080"
16 "path": "./pictrs/old"
20 "path": "./pictrs/sled-repo"
24 "path": "./pictrs/files"
28 .expect("initialize pictrs config");
29 let (lemmy, pictrs) = tokio::join!(start_lemmy_server(), pict_rs::run());
31 pictrs.expect("run pictrs");