From 7cb1f8b11ce795949ecc68e8dfd11426de558f32 Mon Sep 17 00:00:00 2001 From: Iger Date: Sun, 3 Dec 2017 22:49:29 +0200 Subject: [PATCH] - switch username back --- .../com/hierynomus/sshj/IntegrationTest.java | 2 +- src/test/resources/Dockerfile | 19 +++++++++++++------ 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/src/test/java/com/hierynomus/sshj/IntegrationTest.java b/src/test/java/com/hierynomus/sshj/IntegrationTest.java index b0adfddd..861b1a46 100644 --- a/src/test/java/com/hierynomus/sshj/IntegrationTest.java +++ b/src/test/java/com/hierynomus/sshj/IntegrationTest.java @@ -33,7 +33,7 @@ import net.schmizz.sshj.userauth.UserAuthException; public class IntegrationTest { private static final int DOCKER_PORT = 2222; - private static final String USERNAME = "sickp"; + private static final String USERNAME = "sshj"; private final static String SERVER_IP = System.getProperty("serverIP", "127.0.0.1"); @Test @Ignore // Should only be enabled for testing against VM diff --git a/src/test/resources/Dockerfile b/src/test/resources/Dockerfile index 0c0867ec..9bdc08f2 100644 --- a/src/test/resources/Dockerfile +++ b/src/test/resources/Dockerfile @@ -1,8 +1,15 @@ FROM sickp/alpine-sshd:7.5 -ADD https://raw.githubusercontent.com/Igerly/sshj/master/src/test/resources/id_rsa.pub /home/sickp/.ssh/authorized_keys + +ADD https://raw.githubusercontent.com/Igerly/sshj/master/src/test/resources/id_rsa.pub /home/sshj/.ssh/authorized_keys + +ADD test-container/ssh_host_ecdsa_key /etc/ssh/ssh_host_ecdsa_key +ADD test-container/ssh_host_ecdsa_key.pub /etc/ssh/ssh_host_ecdsa_key.pub + RUN \ - echo "root:sunshine" | chpasswd && \ - adduser -D -s /bin/ash sickp && \ - passwd -u sickp && \ - chown -R sickp:sickp /home/sickp - + echo "root:smile" | chpasswd && \ + adduser -D -s /bin/ash sshj && \ + passwd -u sshj && \ + chmod 600 /etc/ssh/ssh_host_ecdsa_key && \ + chmod 644 /etc/ssh/ssh_host_ecdsa_key.pub && \ + chown -R sshj:sshj /home/sshj +