From 10a0d7ad001ff406926d95d983ae1fd2d2b30bd4 Mon Sep 17 00:00:00 2001 From: Ray Slakinski <19767+rays@users.noreply.github.com> Date: Mon, 2 Dec 2024 14:41:47 -0500 Subject: [PATCH] added a dockerfile, updateed install.sh to not prompt to accept new host --- Dockerfile | 16 ++++++++++++++++ install.sh | 6 +++--- 2 files changed, 19 insertions(+), 3 deletions(-) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..68e41fa --- /dev/null +++ b/Dockerfile @@ -0,0 +1,16 @@ +FROM ubuntu:24.04 + +RUN apt-get update && \ + apt-get install -y \ + sshpass + +WORKDIR /nextdns +COPY install.sh . +COPY nextdns.conf . +COPY nextdns_install.sh . +COPY pw . + +RUN chmod +x install.sh +RUN chmod +x nextdns_install.sh + +ENTRYPOINT ["./install.sh"] diff --git a/install.sh b/install.sh index 5c91987..a5c5b90 100755 --- a/install.sh +++ b/install.sh @@ -2,6 +2,6 @@ export NEXTDNS_PASSWORD=$(cat pw) -sshpass -p $NEXTDNS_PASSWORD scp nextdns_install.sh root@192.168.1.1:/root/nextdns_install.sh -sshpass -p $NEXTDNS_PASSWORD scp nextdns.conf root@192.168.1.1:/data/nextdns.conf -sshpass -p $NEXTDNS_PASSWORD ssh root@192.168.1.1 "chmod +x /root/nextdns_install.sh && /root/nextdns_install.sh install" +sshpass -p $NEXTDNS_PASSWORD scp -o "StrictHostKeyChecking no" nextdns_install.sh root@192.168.1.1:/root/nextdns_install.sh +sshpass -p $NEXTDNS_PASSWORD scp -o "StrictHostKeyChecking no" nextdns.conf root@192.168.1.1:/data/nextdns.conf +sshpass -p $NEXTDNS_PASSWORD ssh -o "StrictHostKeyChecking no" root@192.168.1.1 "chmod +x /root/nextdns_install.sh && /root/nextdns_install.sh install"