rustploy 0.1.15

Rustploy PaaS daemon — lightweight self-hosted deployment platform
1
2
3
4
5
6
7
8
9
10
11
//! `Command::GetBuildLogs`: linhas do log de build de um deployment.

use crate::bootstrap::state::AppState;
use shared::Response as RpResponse;

pub async fn handle(state: AppState, deployment_id: String) -> RpResponse {
    match crate::store::build_logs::get_for_deployment(&state.db, &deployment_id).await {
        Ok(lines) => RpResponse::BuildLogs(lines),
        Err(e) => RpResponse::err("DatabaseError", e.to_string()),
    }
}