SpacetimeDB
SpacetimeDB copied to clipboard
Instructions for building SpacetimeDB Standalone + spacetimedb-cli from master, put this into the README
jdetter:
Essentially the instructions are:
cargo build --release -p spacetimedb-cli -p spacetimedb-update -p spacetimedb-standalone
Then users need to put binaries in the right spots. Script that I shared with a user today for this:
# the update command becomes the "spacetime" binary
mkdir -p ~/.local/bin
mv spacetimedb-update-x86_64-unknown-linux-gnu ~/.local/bin/spacetime
# extract the tarball and install
tar xf spacetime-aarch64-unknown-linux-gnu.tar.gz
mkdir -p ~/.local/share/spacetime/bin/1.0.0
mv spacetimedb-cli ~/.local/share/spacetime/bin/1.0.0
mv spacetimedb-standalone ~/.local/share/spacetime/bin/1.0.0
# Set the current version
spacetime version use 1.0.0
localhost:~/SpacetimeDB$ su -
Password:
localhost:~# apk add cargo
fetch http://dl-cdn.alpinelinux.org/alpine/v3.21/main/x86_64/APKINDEX.tar.gz
fetch http://alpine.northrepo.ca/v3.21/main/x86_64/APKINDEX.tar.gz
fetch http://alpine.northrepo.ca/v3.21/community/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.21/community/x86_64/APKINDEX.tar.gz
(1/9) Installing jansson (2.14-r4)
(2/9) Installing binutils (2.43.1-r2)
(3/9) Installing isl26 (0.26-r1)
(4/9) Installing mpfr4 (4.2.1-r0)
(5/9) Installing mpc1 (1.3.1-r1)
(6/9) Installing gcc (14.2.0-r4)
(7/9) Installing musl-dev (1.2.5-r9)
(8/9) Installing rust (1.83.0-r0)
(9/9) Installing cargo (1.83.0-r0)
Executing busybox-1.37.0-r12.trigger
OK: 1480 MiB in 444 packages
localhost:~#
localhost:~/SpacetimeDB$ cargo build --release -p spacetimedb-cli -p spacetimedb-update -p spacetimedb-standalone
error: failed to parse manifest at `/home/user/SpacetimeDB/Cargo.toml`
Caused by:
feature `edition2024` is required
The package requires the Cargo feature called `edition2024`, but that feature is not stabilized in this version of Cargo (1.83.0 (5ffbef321 2024-10-29)).
Consider trying a newer version of Cargo (this may require the nightly release).
See https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#edition-2024 for more information about the status of this feature.
localhost:~/SpacetimeDB$
Linux localhost 6.12.16-0-lts #1-Alpine SMP PREEMPT_DYNAMIC 2025-02-21 15:23:09 x86_64 Linux
localhost:~/SpacetimeDB$ cargo --version
cargo 1.83.0 (5ffbef321 2024-10-29)
@syonfox rustup update and then try again, you just need the latest version of cargo