Compare commits

..

2 commits

Author SHA1 Message Date
3315198bab Merge branch 'main' of https://alm.pragmatismo.com.br/generalbots/gbserver
Some checks failed
GBCI / build (push) Failing after 7m55s
2025-09-19 18:52:15 -03:00
1e94a2856a Update CoreDNS to 1.12.4 and enhance logging format
- Rename llama.cpp directory to llm in system.sh
- Update LlamaCppEmbeddingResponseItem struct field from _index to index
2025-09-19 18:50:56 -03:00
4 changed files with 8 additions and 8 deletions

View file

@ -78,7 +78,7 @@ async fn main() -> std::io::Result<()> {
App::new()
.wrap(Logger::default())
.wrap(Logger::new("%a %{User-Agent}i"))
.wrap(Logger::new("HTTP REQUEST: %a %{User-Agent}i"))
.app_data(app_state.clone())
.service(upload_file)
.service(list_file)

View file

@ -37,13 +37,13 @@ lxc config device add pragmatismo-dns dns-tcp proxy listen=tcp:$GB_PUBLIC_IP:53
lxc exec "${PARAM_TENANT}-dns" -- bash -c "
mkdir /opt/gbo
mkdir /opt/gbo/{bin,conf,data,logs}
mkdir /opt/gbo/{bin,conf,data,logs}
echo 'nameserver 8.8.8.8' > /etc/resolv.conf
apt-get upgrade -y && apt-get install -y wget
wget -qO /opt/gbo/bin/coredns https://github.com/coredns/coredns/releases/download/v1.11.1/coredns_1.11.1_linux_amd64.tgz
wget -qO /opt/gbo/bin/coredns https://github.com/coredns/coredns/releases/download/v1.12.4/coredns_1.12.4_linux_amd64.tgz
tar -xzf /opt/gbo/bin/coredns -C /opt/gbo/bin/
useradd --system --no-create-home --shell /bin/false gbuser
setcap cap_net_bind_service=+ep /opt/gbo/bin/coredns
@ -85,4 +85,4 @@ lxc config device add "${PARAM_TENANT}-dns" dnsdata disk source="$HOST_DATA" pat
lxc config device add "${PARAM_TENANT}-dns" dnsconf disk source="$HOST_CONF" path=/opt/gbo/conf
lxc config device add "${PARAM_TENANT}-dns" dnslogs disk source="$HOST_LOGS" path=/opt/gbo/logs
lxc exec "${PARAM_TENANT}-dns" -- systemctl start dns
lxc exec "${PARAM_TENANT}-dns" -- systemctl start dns

View file

@ -25,9 +25,9 @@ mkdir -p /opt/gbo/logs /opt/gbo/bin /opt/gbo/data /opt/gbo/conf
chown -R gbuser:gbuser /opt/gbo/
wget https://github.com/ggml-org/llama.cpp/releases/download/b6148/llama-b6148-bin-ubuntu-x64.zip
mkdir llama.cpp
mv llama-b6148-bin-ubuntu-x64.zip llama.cpp
cd llama.cpp
mkdir llm
mv llama-b6148-bin-ubuntu-x64.zip llm
cd llm
unzip llama-b6148-bin-ubuntu-x64.zip
mv build/bin/* .
rm build/bin -r

View file

@ -431,7 +431,7 @@ struct LlamaCppEmbeddingRequest {
// FIXED: Handle the stupid nested array format
#[derive(Debug, Deserialize)]
struct LlamaCppEmbeddingResponseItem {
pub _index: usize,
pub index: usize,
pub embedding: Vec<Vec<f32>>, // This is the fucked up part - embedding is an array of arrays
}