ci / docker (push) Successful in 13s
Rust (axum + sqlx) API and worker sharing a Postgres-backed job queue (SKIP LOCKED, heartbeat, reaper, typed statuses), S3 storage with derived keys and a fully private bucket, OIDC photographer login with per-request allowlist checks, client share links with argon2 passwords and lockout, cookie-based image authorization with sliding expiry, hand-rolled spec-compliant streaming ZIP downloads with exact Content-Length, React + Vite gallery frontend, single Docker image, Helm chart for external S3 + Postgres, and Gitea CI. Co-Authored-By: Claude <noreply@anthropic.com>
20 lines
474 B
Rust
20 lines
474 B
Rust
use tracing_subscriber::EnvFilter;
|
|
|
|
use photos::config::Config;
|
|
use photos::jobs;
|
|
use photos::state::AppState;
|
|
|
|
#[tokio::main]
|
|
async fn main() -> anyhow::Result<()> {
|
|
tracing_subscriber::fmt()
|
|
.with_env_filter(
|
|
EnvFilter::try_from_default_env().unwrap_or_else(|_| "info,sqlx=warn".into()),
|
|
)
|
|
.init();
|
|
|
|
let config = Config::from_env()?;
|
|
let state = AppState::new(config).await?;
|
|
jobs::run_worker(state).await;
|
|
Ok(())
|
|
}
|