Skip to content

Commit 3f0ed79

Browse files
fsckTrolldemorted
authored andcommitted
fix scp key and destination handling
1 parent 7a70831 commit 3f0ed79

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/deploy.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,9 @@ use EnokeysError;
77
pub fn deploy(destinations: &[Destination]) -> Result<(), EnokeysError> {
88
for destination in destinations {
99
Command::new("scp")
10-
.args(&["-i", "./data/id_ed25519",
11-
"-P", &format!("{}", destination.port),
10+
.args(&["-P", &format!("{}", destination.port),
1211
"-o", "StrictHostKeyChecking=no",
13-
&destination.authorized_keys_file_name.to_str().unwrap().to_string(), &format!("{}@{}:/home/{}/.ssh/authorized_keys", &destination.userauth_agent, &destination.address, &destination.userauth_agent)])
12+
&destination.authorized_keys_file_name.to_str().unwrap().to_string(), &format!("{}@{}:~/.ssh/authorized_keys", &destination.userauth_agent, &destination.address)])
1413
.status()?;
1514
}
1615
Ok(())

0 commit comments

Comments
 (0)