feat: with ingored host key checking
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
Signed-off-by: kjuulh <contact@kjuulh.io>
This commit is contained in:
parent
cf05cf4228
commit
7daf873e37
@ -1,7 +1,7 @@
|
|||||||
use std::sync::Arc;
|
use std::sync::Arc;
|
||||||
|
|
||||||
use async_trait::async_trait;
|
use async_trait::async_trait;
|
||||||
use dagger_sdk::{Container, Socket};
|
use dagger_sdk::{Container, ContainerWithNewFileOptsBuilder, Socket};
|
||||||
use eyre::Context;
|
use eyre::Context;
|
||||||
|
|
||||||
use crate::{dagger_middleware::DaggerMiddleware, leptos_service::LeptosService};
|
use crate::{dagger_middleware::DaggerMiddleware, leptos_service::LeptosService};
|
||||||
@ -26,7 +26,19 @@ impl DaggerMiddleware for SshAgent {
|
|||||||
|
|
||||||
let socket = self.client.host().unix_socket(&sock_var);
|
let socket = self.client.host().unix_socket(&sock_var);
|
||||||
|
|
||||||
|
let home = container.env_variable("HOME").await?;
|
||||||
|
|
||||||
let c = container
|
let c = container
|
||||||
|
.with_new_file_opts(
|
||||||
|
format!("{home}/.ssh/config"),
|
||||||
|
ContainerWithNewFileOptsBuilder::default().contents(
|
||||||
|
r#"
|
||||||
|
Host *
|
||||||
|
StrictHostKeyChecking no
|
||||||
|
UserKnownHostsFile=/dev/null
|
||||||
|
"#,
|
||||||
|
),
|
||||||
|
)
|
||||||
.with_unix_socket(&sock_var, socket)
|
.with_unix_socket(&sock_var, socket)
|
||||||
.with_env_variable("SSH_AUTH_SOCK", &sock_var);
|
.with_env_variable("SSH_AUTH_SOCK", &sock_var);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user