dagger-components/examples/gitea-cuddle-file-cuddle-please/src/main.rs
kjuulh 0a39e729bc
Some checks failed
continuous-integration/drone/push Build is failing
feat: ssh is always required for with src
Signed-off-by: kjuulh <contact@kjuulh.io>
2023-08-11 20:01:43 +02:00

20 lines
696 B
Rust

use dagger_cuddle_please::{models::CuddlePleaseSrcArgs, DaggerCuddlePleaseAction};
#[tokio::main]
pub async fn main() -> eyre::Result<()> {
let client = dagger_sdk::connect().await?;
DaggerCuddlePleaseAction::dagger(client.clone())
.execute_src(&CuddlePleaseSrcArgs {
cuddle_image: "kasperhermansen/cuddle-please:main-1691504183".into(),
server: dagger_cuddle_please::models::SrcServer::Gitea {
token: std::env::var("CUDDLE_PLEASE_TOKEN")
.expect("CUDDLE_PLEASE_TOKEN to be present"),
},
log_level: Some(dagger_cuddle_please::models::LogLevel::Debug),
})
.await?;
Ok(())
}