From 9d51fcf8c5aff6085e8cc79509ab6b2b7d8a4081 Mon Sep 17 00:00:00 2001 From: Poulette <63922760+PouletteMC@users.noreply.github.com> Date: Thu, 26 Feb 2026 01:03:21 +0100 Subject: [PATCH 1/9] feat: Add SurrealDB Added scripts for SurrealDB, a multi-modal database --- ct/surrealdb.sh | 89 +++++++++++++++++++++++++++++ frontend/public/json/surrealdb.json | 44 ++++++++++++++ install/surrealdb-install.sh | 64 +++++++++++++++++++++ 3 files changed, 197 insertions(+) create mode 100644 ct/surrealdb.sh create mode 100644 frontend/public/json/surrealdb.json create mode 100644 install/surrealdb-install.sh diff --git a/ct/surrealdb.sh b/ct/surrealdb.sh new file mode 100644 index 00000000..c1ba20fe --- /dev/null +++ b/ct/surrealdb.sh @@ -0,0 +1,89 @@ +#!/usr/bin/env bash +COMMUNITY_SCRIPTS_URL="${COMMUNITY_SCRIPTS_URL:-https://git.community-scripts.org/community-scripts/ProxmoxVED/raw/branch/main}" +source <(curl -fsSL "$COMMUNITY_SCRIPTS_URL/misc/build.func") +# Copyright (c) 2021-2026 community-scripts ORG +# Author: PouletteMC +# License: MIT | https://github.com/community-scripts/ProxmoxVED/raw/main/LICENSE +# Source: https://surrealdb.com + +APP="SurrealDB" +var_tags="${var_tags:-database;nosql}" +var_cpu="${var_cpu:-2}" +var_ram="${var_ram:-1024}" +var_disk="${var_disk:-4}" +var_os="${var_os:-debian}" +var_version="${var_version:-13}" +var_unprivileged="${var_unprivileged:-1}" + +header_info "$APP" +variables +color +catch_errors + +function update_script() { + header_info + check_container_storage + check_container_resources + + if [[ ! -f /usr/local/bin/surreal ]]; then + msg_error "No ${APP} Installation Found!" + exit + fi + + UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "${APP} Management" \ + --menu "Select an option:" 12 58 3 \ + "1" "Update SurrealDB" \ + "2" "Switch to Memory Storage" \ + "3" "Switch to Disk Storage (RocksDB)" \ + 3>&1 1>&2 2>&3) || exit + + case "$UPD" in + 1) + RELEASE=$(curl -fsSL https://api.github.com/repos/surrealdb/surrealdb/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') + if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt 2>/dev/null)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then + msg_info "Stopping ${APP}" + systemctl stop surrealdb + msg_ok "Stopped ${APP}" + + msg_info "Updating ${APP} to v${RELEASE}" + $STD bash <(curl -sSf https://install.surrealdb.com) + echo "${RELEASE}" >/opt/${APP}_version.txt + msg_ok "Updated ${APP} to v${RELEASE}" + + msg_info "Starting ${APP}" + systemctl start surrealdb + msg_ok "Started ${APP}" + + msg_ok "Update Successful" + else + msg_ok "No update required. ${APP} is already at v${RELEASE}" + fi + ;; + 2) + msg_info "Switching to Memory Storage" + sed -i 's|^ExecStart=.*|ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 memory|' /etc/systemd/system/surrealdb.service + systemctl daemon-reload + systemctl restart surrealdb + msg_ok "Switched to Memory Storage" + msg_ok "Warning: Data will not persist across restarts" + ;; + 3) + msg_info "Switching to Disk Storage (RocksDB)" + mkdir -p /opt/surrealdb/data + sed -i 's|^ExecStart=.*|ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 rocksdb:///opt/surrealdb/data/srdb.db|' /etc/systemd/system/surrealdb.service + systemctl daemon-reload + systemctl restart surrealdb + msg_ok "Switched to Disk Storage (RocksDB)" + ;; + esac + exit +} + +start +build_container +description + +msg_ok "Completed successfully!\n" +echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}" +echo -e "${INFO}${YW} Access it using the following URL:${CL}" +echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:8000${CL}" diff --git a/frontend/public/json/surrealdb.json b/frontend/public/json/surrealdb.json new file mode 100644 index 00000000..702873ff --- /dev/null +++ b/frontend/public/json/surrealdb.json @@ -0,0 +1,44 @@ +{ + "name": "SurrealDB", + "slug": "surrealdb", + "categories": [ + 8 + ], + "date_created": "2026-02-26", + "type": "ct", + "updateable": true, + "privileged": false, + "interface_port": 8000, + "documentation": "https://surrealdb.com/docs", + "website": "https://surrealdb.com/", + "logo": "https://cdn.jsdelivr.net/gh/selfhst/icons@main/webp/surrealdb.webp", + "config_path": "/opt/surrealdb/.env", + "description": "SurrealDB is a multi-model database that combines the power of document, graph, and relational databases into a single platform, offering real-time queries, built-in permissions, and a simplified backend stack.", + "install_methods": [ + { + "type": "default", + "script": "ct/surrealdb.sh", + "resources": { + "cpu": 2, + "ram": 1024, + "hdd": 4, + "os": "debian", + "version": "13" + } + } + ], + "default_credentials": { + "username": "root", + "password": null + }, + "notes": [ + { + "text": "SurrealDB web interface is available on port 8000.", + "type": "info" + }, + { + "text": "Default credentials are saved in ~/surrealdb.creds.", + "type": "info" + } + ] +} diff --git a/install/surrealdb-install.sh b/install/surrealdb-install.sh new file mode 100644 index 00000000..85d02db9 --- /dev/null +++ b/install/surrealdb-install.sh @@ -0,0 +1,64 @@ +#!/usr/bin/env bash + +# Copyright (c) 2021-2026 community-scripts ORG +# Author: PouletteMC +# License: MIT | https://github.com/community-scripts/ProxmoxVED/raw/main/LICENSE +# Source: https://surrealdb.com + +source /dev/stdin <<<"$FUNCTIONS_FILE_PATH" +color +verb_ip6 +catch_errors +setting_up_container +network_check +update_os + +msg_info "Installing Dependencies" +$STD apt-get install -y \ + curl \ + sudo \ + mc +msg_ok "Installed Dependencies" + +msg_info "Installing SurrealDB" +$STD bash <(curl -sSf https://install.surrealdb.com) +msg_ok "Installed SurrealDB" + +msg_info "Configuring SurrealDB" +mkdir -p /opt/surrealdb/data +SURREALDB_PASS=$(openssl rand -base64 18 | tr -dc 'a-zA-Z0-9' | head -c13) +cat </opt/surrealdb/.env +SURREALDB_PASS=${SURREALDB_PASS} +EOF +{ + echo "SurrealDB Credentials" + echo "Username: root" + echo "Password: ${SURREALDB_PASS}" +} >>~/surrealdb.creds +msg_ok "Configured SurrealDB" + +msg_info "Creating Service" +cat </etc/systemd/system/surrealdb.service +[Unit] +Description=SurrealDB Server +After=network.target + +[Service] +Type=simple +EnvironmentFile=/opt/surrealdb/.env +ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 --user root --pass \${SURREALDB_PASS} rocksdb:///opt/surrealdb/data/srdb.db +Restart=on-failure +RestartSec=5 + +[Install] +WantedBy=multi-user.target +EOF +systemctl enable -q --now surrealdb +msg_ok "Created Service" + +RELEASE=$(curl -fsSL https://api.github.com/repos/surrealdb/surrealdb/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') +echo "${RELEASE}" >/opt/SurrealDB_version.txt + +motd_ssh +customize +cleanup_lxc From a5c24cfc49b4ea88dca87cedbef8f86a4b52576f Mon Sep 17 00:00:00 2001 From: Poulette Date: Thu, 26 Feb 2026 01:17:22 +0100 Subject: [PATCH 2/9] Keep authentication when switching storage modes Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> --- ct/surrealdb.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ct/surrealdb.sh b/ct/surrealdb.sh index c1ba20fe..6c3de96d 100644 --- a/ct/surrealdb.sh +++ b/ct/surrealdb.sh @@ -61,7 +61,7 @@ function update_script() { ;; 2) msg_info "Switching to Memory Storage" - sed -i 's|^ExecStart=.*|ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 memory|' /etc/systemd/system/surrealdb.service + sed -i 's|^ExecStart=.*|ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 --user root --pass ${SURREALDB_PASS} memory|' /etc/systemd/system/surrealdb.service systemctl daemon-reload systemctl restart surrealdb msg_ok "Switched to Memory Storage" From 9716fcded14335b8c92f9df5c5687b755b50144d Mon Sep 17 00:00:00 2001 From: Poulette Date: Thu, 26 Feb 2026 01:17:59 +0100 Subject: [PATCH 3/9] Keeps authentication on mode switch Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> --- ct/surrealdb.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ct/surrealdb.sh b/ct/surrealdb.sh index 6c3de96d..36961a0d 100644 --- a/ct/surrealdb.sh +++ b/ct/surrealdb.sh @@ -70,7 +70,7 @@ function update_script() { 3) msg_info "Switching to Disk Storage (RocksDB)" mkdir -p /opt/surrealdb/data - sed -i 's|^ExecStart=.*|ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 rocksdb:///opt/surrealdb/data/srdb.db|' /etc/systemd/system/surrealdb.service + sed -i 's|^ExecStart=.*|ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 --user root --pass ${SURREALDB_PASS} rocksdb:///opt/surrealdb/data/srdb.db|' /etc/systemd/system/surrealdb.service systemctl daemon-reload systemctl restart surrealdb msg_ok "Switched to Disk Storage (RocksDB)" From 0f6966bbdf9b3e4b21efd09897eabe4033ab38b9 Mon Sep 17 00:00:00 2001 From: Poulette Date: Thu, 26 Feb 2026 01:18:34 +0100 Subject: [PATCH 4/9] Remove redundant package installs Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> --- install/surrealdb-install.sh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/install/surrealdb-install.sh b/install/surrealdb-install.sh index 85d02db9..baf5349d 100644 --- a/install/surrealdb-install.sh +++ b/install/surrealdb-install.sh @@ -14,9 +14,7 @@ network_check update_os msg_info "Installing Dependencies" -$STD apt-get install -y \ - curl \ - sudo \ +$STD apt install -y \ mc msg_ok "Installed Dependencies" From c90a7dd972538f26030295a7e304da244b684a81 Mon Sep 17 00:00:00 2001 From: Poulette Date: Thu, 26 Feb 2026 01:19:02 +0100 Subject: [PATCH 5/9] Hardcode app name in error messages Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> --- ct/surrealdb.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ct/surrealdb.sh b/ct/surrealdb.sh index 36961a0d..4c9410e8 100644 --- a/ct/surrealdb.sh +++ b/ct/surrealdb.sh @@ -26,7 +26,7 @@ function update_script() { check_container_resources if [[ ! -f /usr/local/bin/surreal ]]; then - msg_error "No ${APP} Installation Found!" + msg_error "No SurrealDB Installation Found!" exit fi From 810902fce18b260ac465d79e2fdde241e5599be6 Mon Sep 17 00:00:00 2001 From: Poulette <63922760+PouletteMC@users.noreply.github.com> Date: Thu, 26 Feb 2026 23:33:34 +0100 Subject: [PATCH 6/9] Use GH release deploy for SurrealDB Replace the old curl-based installer and interactive update menu with unified GitHub release deployment helpers. ct/surrealdb.sh now checks for a new surrealdb release via check_for_gh_release, stops the service, uses fetch_and_deploy_gh_release to deploy the prebuilt binary to /usr/local/bin, sets exec permissions, and restarts the service (also use ${APP} in an error message). The previous menu-driven update and storage-switch options (memory vs rocksdb) were removed. install/surrealdb-install.sh now skips the removed mc dependency install, uses fetch_and_deploy_gh_release instead of the install.surrealdb.com script, makes the binary executable, and no longer writes a release-version file. Overall moves to a consistent release fetch/deploy flow and simplifies update/install logic. --- ct/surrealdb.sh | 57 ++++++++---------------------------- install/surrealdb-install.sh | 11 ++----- 2 files changed, 14 insertions(+), 54 deletions(-) diff --git a/ct/surrealdb.sh b/ct/surrealdb.sh index 4c9410e8..925321fc 100644 --- a/ct/surrealdb.sh +++ b/ct/surrealdb.sh @@ -26,56 +26,23 @@ function update_script() { check_container_resources if [[ ! -f /usr/local/bin/surreal ]]; then - msg_error "No SurrealDB Installation Found!" + msg_error "No ${APP} Installation Found!" exit fi - UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "${APP} Management" \ - --menu "Select an option:" 12 58 3 \ - "1" "Update SurrealDB" \ - "2" "Switch to Memory Storage" \ - "3" "Switch to Disk Storage (RocksDB)" \ - 3>&1 1>&2 2>&3) || exit + if check_for_gh_release "surrealdb" "surrealdb/surrealdb"; then + msg_info "Stopping Service" + systemctl stop surrealdb + msg_ok "Stopped Service" - case "$UPD" in - 1) - RELEASE=$(curl -fsSL https://api.github.com/repos/surrealdb/surrealdb/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') - if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt 2>/dev/null)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then - msg_info "Stopping ${APP}" - systemctl stop surrealdb - msg_ok "Stopped ${APP}" + fetch_and_deploy_gh_release "surrealdb" "surrealdb/surrealdb" "prebuild" "latest" "/usr/local/bin" "surreal-v*.linux-amd64.tgz" + chmod +x /usr/local/bin/surreal - msg_info "Updating ${APP} to v${RELEASE}" - $STD bash <(curl -sSf https://install.surrealdb.com) - echo "${RELEASE}" >/opt/${APP}_version.txt - msg_ok "Updated ${APP} to v${RELEASE}" - - msg_info "Starting ${APP}" - systemctl start surrealdb - msg_ok "Started ${APP}" - - msg_ok "Update Successful" - else - msg_ok "No update required. ${APP} is already at v${RELEASE}" - fi - ;; - 2) - msg_info "Switching to Memory Storage" - sed -i 's|^ExecStart=.*|ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 --user root --pass ${SURREALDB_PASS} memory|' /etc/systemd/system/surrealdb.service - systemctl daemon-reload - systemctl restart surrealdb - msg_ok "Switched to Memory Storage" - msg_ok "Warning: Data will not persist across restarts" - ;; - 3) - msg_info "Switching to Disk Storage (RocksDB)" - mkdir -p /opt/surrealdb/data - sed -i 's|^ExecStart=.*|ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 --user root --pass ${SURREALDB_PASS} rocksdb:///opt/surrealdb/data/srdb.db|' /etc/systemd/system/surrealdb.service - systemctl daemon-reload - systemctl restart surrealdb - msg_ok "Switched to Disk Storage (RocksDB)" - ;; - esac + msg_info "Starting Service" + systemctl start surrealdb + msg_ok "Started Service" + msg_ok "Updated successfully!" + fi exit } diff --git a/install/surrealdb-install.sh b/install/surrealdb-install.sh index baf5349d..0947df87 100644 --- a/install/surrealdb-install.sh +++ b/install/surrealdb-install.sh @@ -13,13 +13,9 @@ setting_up_container network_check update_os -msg_info "Installing Dependencies" -$STD apt install -y \ - mc -msg_ok "Installed Dependencies" - msg_info "Installing SurrealDB" -$STD bash <(curl -sSf https://install.surrealdb.com) +fetch_and_deploy_gh_release "surrealdb" "surrealdb/surrealdb" "prebuild" "latest" "/usr/local/bin" "surreal-v*.linux-amd64.tgz" +chmod +x /usr/local/bin/surreal msg_ok "Installed SurrealDB" msg_info "Configuring SurrealDB" @@ -54,9 +50,6 @@ EOF systemctl enable -q --now surrealdb msg_ok "Created Service" -RELEASE=$(curl -fsSL https://api.github.com/repos/surrealdb/surrealdb/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') -echo "${RELEASE}" >/opt/SurrealDB_version.txt - motd_ssh customize cleanup_lxc From 5526825a2abe47a776d8d7f688db6ec459013178 Mon Sep 17 00:00:00 2001 From: Poulette <63922760+PouletteMC@users.noreply.github.com> Date: Fri, 27 Feb 2026 00:07:54 +0100 Subject: [PATCH 7/9] Placeholder Placeholder while waiting for slfhts to add the icon to their library --- frontend/public/json/surrealdb.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/public/json/surrealdb.json b/frontend/public/json/surrealdb.json index 702873ff..a7c8182f 100644 --- a/frontend/public/json/surrealdb.json +++ b/frontend/public/json/surrealdb.json @@ -11,7 +11,7 @@ "interface_port": 8000, "documentation": "https://surrealdb.com/docs", "website": "https://surrealdb.com/", - "logo": "https://cdn.jsdelivr.net/gh/selfhst/icons@main/webp/surrealdb.webp", + "logo": "https://surrealdb.com/assets/static/f8ce1df8b5823f08.7t3KDG7y.webp", "config_path": "/opt/surrealdb/.env", "description": "SurrealDB is a multi-model database that combines the power of document, graph, and relational databases into a single platform, offering real-time queries, built-in permissions, and a simplified backend stack.", "install_methods": [ From af1f6b44c02a497cde104051ca809e7f1bcaf79c Mon Sep 17 00:00:00 2001 From: Poulette Date: Sun, 1 Mar 2026 17:09:02 +0100 Subject: [PATCH 8/9] fix(surrealdb): address PR review feedback - Deploy binary to /opt/surrealdb with symlink to /usr/local/bin - Use literal 'SurrealDB' in messages instead of ${APP} - Fix installation check path to /opt/surrealdb/surreal - Update ExecStart to use /opt/surrealdb/surreal - Use selfhst CDN logo URL and capitalize 'Debian' in JSON - Capitalize 'Completed Successfully' to match conventions --- ct/surrealdb.sh | 10 ++-- frontend/public/json/surrealdb.json | 82 ++++++++++++++--------------- install/surrealdb-install.sh | 7 +-- 3 files changed, 49 insertions(+), 50 deletions(-) diff --git a/ct/surrealdb.sh b/ct/surrealdb.sh index 925321fc..27f01924 100644 --- a/ct/surrealdb.sh +++ b/ct/surrealdb.sh @@ -25,8 +25,8 @@ function update_script() { check_container_storage check_container_resources - if [[ ! -f /usr/local/bin/surreal ]]; then - msg_error "No ${APP} Installation Found!" + if [[ ! -f /opt/surrealdb/surreal ]]; then + msg_error "No SurrealDB Installation Found!" exit fi @@ -35,8 +35,8 @@ function update_script() { systemctl stop surrealdb msg_ok "Stopped Service" - fetch_and_deploy_gh_release "surrealdb" "surrealdb/surrealdb" "prebuild" "latest" "/usr/local/bin" "surreal-v*.linux-amd64.tgz" - chmod +x /usr/local/bin/surreal + fetch_and_deploy_gh_release "surrealdb" "surrealdb/surrealdb" "prebuild" "latest" "/opt/surrealdb" "surreal-v*.linux-amd64.tgz" + chmod +x /opt/surrealdb/surreal msg_info "Starting Service" systemctl start surrealdb @@ -50,7 +50,7 @@ start build_container description -msg_ok "Completed successfully!\n" +msg_ok "Completed Successfully!\n" echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}" echo -e "${INFO}${YW} Access it using the following URL:${CL}" echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:8000${CL}" diff --git a/frontend/public/json/surrealdb.json b/frontend/public/json/surrealdb.json index a7c8182f..fb6ddc31 100644 --- a/frontend/public/json/surrealdb.json +++ b/frontend/public/json/surrealdb.json @@ -1,44 +1,42 @@ { - "name": "SurrealDB", - "slug": "surrealdb", - "categories": [ - 8 - ], - "date_created": "2026-02-26", - "type": "ct", - "updateable": true, - "privileged": false, - "interface_port": 8000, - "documentation": "https://surrealdb.com/docs", - "website": "https://surrealdb.com/", - "logo": "https://surrealdb.com/assets/static/f8ce1df8b5823f08.7t3KDG7y.webp", - "config_path": "/opt/surrealdb/.env", - "description": "SurrealDB is a multi-model database that combines the power of document, graph, and relational databases into a single platform, offering real-time queries, built-in permissions, and a simplified backend stack.", - "install_methods": [ - { - "type": "default", - "script": "ct/surrealdb.sh", - "resources": { - "cpu": 2, - "ram": 1024, - "hdd": 4, - "os": "debian", - "version": "13" - } - } - ], - "default_credentials": { - "username": "root", - "password": null - }, - "notes": [ - { - "text": "SurrealDB web interface is available on port 8000.", - "type": "info" - }, - { - "text": "Default credentials are saved in ~/surrealdb.creds.", - "type": "info" - } - ] + "name": "SurrealDB", + "slug": "surrealdb", + "categories": [8], + "date_created": "2026-02-26", + "type": "ct", + "updateable": true, + "privileged": false, + "interface_port": 8000, + "documentation": "https://surrealdb.com/docs", + "website": "https://surrealdb.com/", + "logo": "https://cdn.jsdelivr.net/gh/selfhst/icons@main/webp/surrealdb.webp", + "config_path": "/opt/surrealdb/.env", + "description": "SurrealDB is a multi-model database that combines the power of document, graph, and relational databases into a single platform, offering real-time queries, built-in permissions, and a simplified backend stack.", + "install_methods": [ + { + "type": "default", + "script": "ct/surrealdb.sh", + "resources": { + "cpu": 2, + "ram": 1024, + "hdd": 4, + "os": "Debian", + "version": "13" + } + } + ], + "default_credentials": { + "username": "root", + "password": null + }, + "notes": [ + { + "text": "SurrealDB web interface is available on port 8000.", + "type": "info" + }, + { + "text": "Default credentials are saved in ~/surrealdb.creds.", + "type": "info" + } + ] } diff --git a/install/surrealdb-install.sh b/install/surrealdb-install.sh index 0947df87..3cd93844 100644 --- a/install/surrealdb-install.sh +++ b/install/surrealdb-install.sh @@ -14,8 +14,9 @@ network_check update_os msg_info "Installing SurrealDB" -fetch_and_deploy_gh_release "surrealdb" "surrealdb/surrealdb" "prebuild" "latest" "/usr/local/bin" "surreal-v*.linux-amd64.tgz" -chmod +x /usr/local/bin/surreal +fetch_and_deploy_gh_release "surrealdb" "surrealdb/surrealdb" "prebuild" "latest" "/opt/surrealdb" "surreal-v*.linux-amd64.tgz" +chmod +x /opt/surrealdb/surreal +ln -sf /opt/surrealdb/surreal /usr/local/bin/surreal msg_ok "Installed SurrealDB" msg_info "Configuring SurrealDB" @@ -40,7 +41,7 @@ After=network.target [Service] Type=simple EnvironmentFile=/opt/surrealdb/.env -ExecStart=/usr/local/bin/surreal start --bind 0.0.0.0:8000 --user root --pass \${SURREALDB_PASS} rocksdb:///opt/surrealdb/data/srdb.db +ExecStart=/opt/surrealdb/surreal start --bind 0.0.0.0:8000 --user root --pass \${SURREALDB_PASS} rocksdb:///opt/surrealdb/data/srdb.db Restart=on-failure RestartSec=5 From 66e16ba9744df3c332679e9efd578a4ebcfe78f6 Mon Sep 17 00:00:00 2001 From: Poulette Date: Wed, 4 Mar 2026 14:30:10 +0100 Subject: [PATCH 9/9] Use GitHub raw URL for build.func --- ct/surrealdb.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ct/surrealdb.sh b/ct/surrealdb.sh index 27f01924..70a35d31 100644 --- a/ct/surrealdb.sh +++ b/ct/surrealdb.sh @@ -1,6 +1,5 @@ #!/usr/bin/env bash -COMMUNITY_SCRIPTS_URL="${COMMUNITY_SCRIPTS_URL:-https://git.community-scripts.org/community-scripts/ProxmoxVED/raw/branch/main}" -source <(curl -fsSL "$COMMUNITY_SCRIPTS_URL/misc/build.func") +source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVED/main/misc/build.func) # Copyright (c) 2021-2026 community-scripts ORG # Author: PouletteMC # License: MIT | https://github.com/community-scripts/ProxmoxVED/raw/main/LICENSE