Signed-off-by: kjuulh <contact@kjuulh.io>
This commit is contained in:
parent
939c9f8961
commit
951051a4fe
433
Cargo.lock
generated
433
Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@ -6,7 +6,7 @@ edition = "2021"
|
||||
[dependencies]
|
||||
tokio.workspace = true
|
||||
|
||||
dagger-sdk = "0.9.8"
|
||||
dagger-sdk = "0.11.10"
|
||||
eyre = { version = "0.6.12" }
|
||||
|
||||
dagger-components = { git = "https://git.front.kjuulh.io/kjuulh/dagger-components", branch = "main" }
|
||||
|
@ -7,42 +7,44 @@ const BIN_NAME: &str = "cuddle-rust-cli-plan";
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() -> eyre::Result<()> {
|
||||
let client = dagger_sdk::connect().await?;
|
||||
dagger_sdk::connect(|client| async move {
|
||||
let service = &RustService::from(client.clone())
|
||||
.with_arch(Architecture::Amd64)
|
||||
.with_os(Os::Linux)
|
||||
.with_apt(&[
|
||||
"clang",
|
||||
"libssl-dev",
|
||||
"libz-dev",
|
||||
"libgit2-dev",
|
||||
"git",
|
||||
"openssh-client",
|
||||
])
|
||||
.with_apt_release(&["git", "openssh-client"])
|
||||
.with_docker_cli()
|
||||
.with_cuddle_cli()
|
||||
.with_kubectl()
|
||||
.with_apt_ca_certificates()
|
||||
.with_workspace_crates()
|
||||
.await
|
||||
.with_mold("2.3.3")
|
||||
.with_bin_name(BIN_NAME)
|
||||
.with_deployment(false)
|
||||
.with_dagger_bin("0.9.8")
|
||||
.to_owned();
|
||||
|
||||
let service = &RustService::from(client.clone())
|
||||
.with_arch(Architecture::Amd64)
|
||||
.with_os(Os::Linux)
|
||||
.with_apt(&[
|
||||
"clang",
|
||||
"libssl-dev",
|
||||
"libz-dev",
|
||||
"libgit2-dev",
|
||||
"git",
|
||||
"openssh-client",
|
||||
])
|
||||
.with_apt_release(&["git", "openssh-client"])
|
||||
.with_docker_cli()
|
||||
.with_cuddle_cli()
|
||||
.with_kubectl()
|
||||
.with_apt_ca_certificates()
|
||||
.with_workspace_crates()
|
||||
.await
|
||||
.with_mold("2.3.3")
|
||||
.with_bin_name(BIN_NAME)
|
||||
.with_deployment(false)
|
||||
.with_dagger_bin("0.9.8")
|
||||
.to_owned();
|
||||
let drone_templater = &DroneTemplater::new(client, "templates/cuddle-rust-cli-plan.yaml")
|
||||
.with_variable("bin_name", BIN_NAME)
|
||||
.to_owned();
|
||||
|
||||
let drone_templater = &DroneTemplater::new(client, "templates/cuddle-rust-cli-plan.yaml")
|
||||
.with_variable("bin_name", BIN_NAME)
|
||||
.to_owned();
|
||||
|
||||
CuddleCI::default()
|
||||
.with_pull_request(service)
|
||||
.with_main(service)
|
||||
.with_main(drone_templater)
|
||||
.execute(std::env::args())
|
||||
.await?;
|
||||
CuddleCI::default()
|
||||
.with_pull_request(service)
|
||||
.with_main(service)
|
||||
.with_main(drone_templater)
|
||||
.execute(std::env::args())
|
||||
.await?;
|
||||
Ok(())
|
||||
})
|
||||
.await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
@ -6,7 +6,7 @@ edition = "2021"
|
||||
[dependencies]
|
||||
tokio.workspace = true
|
||||
|
||||
dagger-sdk = "0.9.8"
|
||||
dagger-sdk = "0.11.10"
|
||||
eyre = { version = "0.6.12" }
|
||||
|
||||
dagger-components = { git = "https://git.front.kjuulh.io/kjuulh/dagger-components", branch = "main" }
|
||||
|
@ -6,29 +6,32 @@ use cuddle_ci::{cuddle_please, CuddleCI};
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() -> eyre::Result<()> {
|
||||
let client = dagger_sdk::connect().await?;
|
||||
let cuddle_file = CuddleFile::from_cuddle_file().await?;
|
||||
dagger_sdk::connect(|client| async move {
|
||||
let cuddle_file = CuddleFile::from_cuddle_file().await?;
|
||||
|
||||
let service = &RustService::from(client.clone())
|
||||
.with_arch(Architecture::Amd64)
|
||||
.with_os(Os::Linux)
|
||||
.with_apt(&["libssl-dev", "libz-dev", "libpq-dev", "protobuf-compiler"])
|
||||
.with_apt_release(&["libssl-dev", "libz-dev", "libpq-dev"])
|
||||
.with_cuddle_file(&cuddle_file)
|
||||
.with_apt_ca_certificates()
|
||||
.with_workspace_crates()
|
||||
.await
|
||||
.with_mold("2.3.3")
|
||||
.to_owned();
|
||||
let service = &RustService::from(client.clone())
|
||||
.with_arch(Architecture::Amd64)
|
||||
.with_os(Os::Linux)
|
||||
.with_apt(&["libssl-dev", "libz-dev", "libpq-dev", "protobuf-compiler"])
|
||||
.with_apt_release(&["libssl-dev", "libz-dev", "libpq-dev"])
|
||||
.with_cuddle_file(&cuddle_file)
|
||||
.with_apt_ca_certificates()
|
||||
.with_workspace_crates()
|
||||
.await
|
||||
.with_mold("2.3.3")
|
||||
.to_owned();
|
||||
|
||||
let cuddle_please = &cuddle_please::CuddlePlease::new(client.clone());
|
||||
let cuddle_please = &cuddle_please::CuddlePlease::new(client.clone());
|
||||
|
||||
CuddleCI::default()
|
||||
.with_pull_request(service)
|
||||
.with_main(service)
|
||||
.with_main(cuddle_please)
|
||||
.execute(std::env::args())
|
||||
.await?;
|
||||
CuddleCI::default()
|
||||
.with_pull_request(service)
|
||||
.with_main(service)
|
||||
.with_main(cuddle_please)
|
||||
.execute(std::env::args())
|
||||
.await?;
|
||||
|
||||
Ok(())
|
||||
})
|
||||
.await?;
|
||||
Ok(())
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user