Skip to content

Commit

Permalink
feat: Add StrictHostKeyChecking=no to ssh (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
egyptianbman authored Oct 20, 2021
1 parent 53c422f commit a337c75
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/domain/connections.rs
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ impl SshConnection for ContainerChoice {
cmd: Vec<String>,
) -> String {
format!(
"ssh -i {identity_file} -p {bastion_port} -A -t {bastion_user}@{dns_name} \"ssh -A -t {ec2_user}@{ip} \\\"docker exec -it --detach-keys 'ctrl-q,q' {docker_id} {cmd}\\\"\"",
"ssh -o StrictHostKeyChecking=no -i {identity_file} -p {bastion_port} -A -t {bastion_user}@{dns_name} \"ssh -o StrictHostKeyChecking=no -A -t {ec2_user}@{ip} \\\"docker exec -it --detach-keys 'ctrl-q,q' {docker_id} {cmd}\\\"\"",
identity_file=ssh_identity_file,
bastion_port=bastion_port,
bastion_user=bastion_user,
Expand Down Expand Up @@ -248,7 +248,7 @@ impl SshConnection for HostConnection {
cmd: Vec<String>,
) -> String {
format!(
"ssh -i {identity_file} -p {bastion_port} -A -t {bastion_user}@{dns_name} ssh -A -t {ec2_user}@{ip} {cmd}",
"ssh -o StrictHostKeyChecking=no -i {identity_file} -p {bastion_port} -A -t {bastion_user}@{dns_name} ssh -o StrictHostKeyChecking=no -A -t {ec2_user}@{ip} {cmd}",
identity_file=ssh_identity_file,
bastion_port=bastion_port,
bastion_user=bastion_user,
Expand Down

0 comments on commit a337c75

Please sign in to comment.