From 3adeac38008fb4e73df3cca5e46a9787090fe6c8 Mon Sep 17 00:00:00 2001 From: Sadeep Madurange Date: Sat, 12 Sep 2026 10:06:16 +0800 Subject: Sample ssh config and readme. --- README.txt | 14 +++++++++----- lexd-spool.sh | 4 ++-- ssh-config | 7 +++++++ 3 files changed, 18 insertions(+), 7 deletions(-) create mode 100644 ssh-config diff --git a/README.txt b/README.txt index 9bdb9e3..c42f8db 100644 --- a/README.txt +++ b/README.txt @@ -1,10 +1,14 @@ USAGE -1. Install: make install -2. Set datasize-cur/datasize-max to 3G/4G for daemon class. -3. Place model file in /var/lexd/model.gguf. -4. Start service: rcctl start lexd -5. Connect, type prompt, hit enter: nc -U /var/run/lexd/sock + 1. Install: make install + 2. Set datasize-cur/datasize-max to 3G/4G for daemon class. + 3. Place model file in /var/lexd/model.gguf. + 4. Start service: rcctl start lexd + 5. Add lex-spool config to ~/.ssh/config + +TEST + + 1. Connect, type prompt, hit enter: nc -U /var/run/lexd/sock INSTALL diff --git a/lexd-spool.sh b/lexd-spool.sh index 9b9b723..ec6fc7b 100644 --- a/lexd-spool.sh +++ b/lexd-spool.sh @@ -91,8 +91,8 @@ while true; do exit 1 fi - # Strip leading '<' character if present - response="${response#<}" + # Strip leading stray characters if present + response="${response#[<\"]}" # Extract first word (lowercased) target_word=$(print -r -- "${response}" \ diff --git a/ssh-config b/ssh-config new file mode 100644 index 0000000..cd70866 --- /dev/null +++ b/ssh-config @@ -0,0 +1,7 @@ +Host lex-spool + HostName xxx.xx.xxx.xxx + User lex + Port 22 + IdentityFile /home/_lexd/.ssh/id_lex + ConnectTimeout 5 + -- cgit v1.2.3