Files
logos-messaging-module/scripts/install-node-tools.sh
T
Igor SirotinandClaude Opus 4.8 ab904fd4c2 docs: add prebuilt-binary run path to run-node guide (#54)
* docs: add prebuilt-binary run path (no build) to run-node guide

Document running a node without building from source: download the
logoscore daemon AppImage, the lgpm package manager, and this module's
prebuilt delivery_module.lgx from the logos-modules release, install with
lgpm, and boot the node — same load-module / createNode / start calls,
defaulting to the logos.test fleet.

Splits "Without Docker" into "prebuilt binaries" (Linux only) and "build
with Nix" (any platform). All three methods default to logos.test.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* docs: fix prebuilt module source to logos-modules-release (logos.test)

The modules release repo was renamed to logos-modules-release and now
publishes per-module, versioned releases (no rolling `latest`). Point the
prebuilt delivery_module download at the versioned tag/asset
(delivery_module-v0.1.3 / delivery_module-0.1.3.lgx) and note that the
logos.test preset needs delivery_module >= 0.1.3 — earlier builds only
support twn and logos.dev.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* docs: prebuilt path uses lgpd + covers macOS

Rework the prebuilt-binary section around the canonical downloader flow
used by logos-docker: fetch the module with `lgpd download delivery_module`
(its built-in catalog is logos-modules-release) and install with
`lgpm install`, instead of curling a release asset by hand.

Add macOS (Apple Silicon) alongside Linux — logoscore/lgpd/lgpm are all
published for both. Keep the note that logos.test needs delivery_module
>= 0.1.3, and mention the direct-.lgx fallback.

Verified end-to-end on macOS (host) and Linux (VM): lgpd download ->
lgpm install -> logoscore createNode @logos-test.json -> start, with the
node dialing the logos.test bootstrap fleet on both.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* docs: resolve tools from latest release, move Metrics to run-node

- Prebuilt path: drop pinned pre-release tags; a latest()/dl() helper
  pair resolves each tool's newest release from the GitHub API, so no
  version is hardcoded.
- Move the Metrics (openmetrics scrape) instructions from README into
  run-node.md as a "## Metrics" section; README keeps the API reference
  and links to it.
- Drop the trailing note block from the prebuilt section.

Verified the exact doc commands on macOS: latest()/dl() -> tools on PATH,
lgpd download delivery_module -> 0.1.3, lgpm install.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* docs: simplify prebuilt setup to a one-line install script

Replace the two helper functions + per-OS download blocks with
scripts/install-node-tools.sh, which detects OS/arch, resolves the latest
release of logoscore/lgpd/lgpm, and drops them in ./bin. The doc shrinks
to a curl one-liner + the lgpd/lgpm/run steps.

The script handles the per-OS packaging (Linux AppImage vs macOS app
tree) so the doc no longer has to. Verified on macOS + Linux: the script
installs all three working CLIs; lgpd download -> lgpm install -> boot.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* docs: pin tool releases instead of resolving latest

Drop the GitHub API lookup; install-node-tools.sh now pins the current
releases of logoscore/lgpd/lgpm via *_TAG vars (bump to upgrade). Removes
the unauthenticated API call (and its rate-limit failure mode) from the
install path.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-24 17:18:47 +01:00

57 lines
1.9 KiB
Bash
Executable File

#!/bin/sh
# Download the Logos node CLIs — logoscore, lgpd, lgpm — into ./bin.
#
# Unpacks a pinned release of each tool for the host OS/arch. Works on Linux
# (x86_64/aarch64) and macOS (Apple Silicon). To move to newer builds, bump the
# *_TAG values below. After it finishes: export PATH="$PWD/bin:$PATH"
set -eu
# Pinned tool releases (latest at time of writing).
LOGOSCORE_TAG=pre-release-8002477-4
LGPD_TAG=pre-release-99d70db-7
LGPM_TAG=pre-release-05b2cf8-7
os=$(uname -s | tr '[:upper:]' '[:lower:]')
if [ "$os" = darwin ]; then os=macos; fi
arch=$(uname -m)
if [ "$arch" = arm64 ]; then arch=aarch64; fi
case "$os" in
linux|macos) ;;
*) echo "unsupported OS: $os (Linux/macOS only)" >&2; exit 1 ;;
esac
bin="$PWD/bin"
mkdir -p "$bin"
# fetch <repo> <tool> <tag>: download <tool>-<arch>-<os>.tar.gz, expose ./bin/<tool>
fetch() {
repo=$1; tool=$2; tag=$3
echo " $tool ($tag)"
tmp=$(mktemp -d)
curl -fsSL "https://github.com/logos-co/$repo/releases/download/$tag/$tool-$arch-$os.tar.gz" \
| tar xz -C "$tmp"
if [ "$os" = macos ]; then
# tarball is <tool>-<arch>-macos/{bin,lib,...}; the binary finds its bundled
# libs/modules relative to its real path, so wrap it (a symlink would break
# that resolution) rather than linking.
rm -rf "$bin/$tool-$arch-macos"
mv "$tmp/$tool-$arch-macos" "$bin/"
printf '#!/bin/sh\nexec "%s/%s-%s-macos/bin/%s" "$@"\n' "$bin" "$tool" "$arch" "$tool" > "$bin/$tool"
chmod +x "$bin/$tool"
else
# tarball is a single <tool>-<arch>.AppImage
mv "$tmp/$tool-$arch.AppImage" "$bin/$tool"
chmod +x "$bin/$tool"
fi
rm -rf "$tmp"
}
echo "Installing Logos node tools for $os/$arch into $bin ..."
fetch logos-logoscore-cli logoscore "$LOGOSCORE_TAG"
fetch logos-package-downloader lgpd "$LGPD_TAG"
fetch logos-package-manager lgpm "$LGPM_TAG"
echo
echo "Done. Put them on your PATH:"
echo " export PATH=\"$bin:\$PATH\""