]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
Dockerfile: Set up SSH client incl. generated key
authorZack Cerza <zack@redhat.com>
Fri, 14 Jan 2022 22:55:09 +0000 (15:55 -0700)
committerZack Cerza <zack@redhat.com>
Mon, 28 Mar 2022 21:28:37 +0000 (15:28 -0600)
Signed-off-by: Zack Cerza <zack@redhat.com>
docs/docker-compose/Dockerfile

index 41f27b6c5dde51a104dea6f688781e368a98b4b9..45e731cbf5f8b1089753f31c437278b1a5c7be41 100644 (file)
@@ -5,7 +5,12 @@ COPY .teuthology.yaml ./root
 WORKDIR /teuthology
 RUN chmod +x /teuthology/bootstrap && \
     mkdir ../archive_dir && \
-    mkdir log
+    mkdir log && \
+    mkdir $HOME/.ssh && \
+    touch $HOME/.ssh/id_ed25519 && \
+    chmod 600 $HOME/.ssh/id_ed25519 && \
+    echo "StrictHostKeyChecking=no" > $HOME/.ssh/config && \
+    echo "UserKnownHostsFile=/dev/null" >> $HOME/.ssh/config
 RUN apt-get update && \
     apt-get install -y \
     git \
@@ -23,7 +28,8 @@ RUN apt-get update && \
     lsb-release && \
     apt-get clean all
 RUN ./bootstrap
-CMD ./virtualenv/bin/teuthology-suite \
+CMD echo "$SSH_PRIVKEY" > $HOME/.ssh/id_ed25519 && \
+    ./virtualenv/bin/teuthology-suite \
     -v --ceph-repo https://github.com/ceph/ceph.git \
     --suite-repo https://github.com/ceph/ceph.git \
     -c master -m testnode --subset 9000/100000 --limit 1 \