Commit graph

17 commits

Author SHA1 Message Date
Charles Hall
0bd2c43dab
don't strip binary for dev builds 2024-06-05 16:42:40 -07:00
Charles Hall
972c25beca
remove unnecessary whitespace 2024-06-05 16:42:16 -07:00
Benjamin Lee
fa48c48d52
add all-features devshell
Because the nix rocksdb build depends on the jemalloc feature, you need
to use a different devshell when passing --all-features to cargo than
the default.
2024-05-30 21:19:08 -07:00
Benjamin Lee
8f24ac1f27
do default-feature unification in nix
Some of the features affect nix dependencies, so we need to have a
full feature list available when constructing the nix derivation. This
incidentally fixes the bug where we weren't enabling jemalloc on rocksdb
in CI/devshells, because jemalloc is now a default feature. It does not
fix the more general class of that issue, where CI is performing an
`--all-features` build in a nix devshell built for default-features.

I am now passing `--no-default-features` to cargo, and having it use our
unified feature list rather than duplicating the unification inside cargo.
2024-05-30 21:19:08 -07:00
Benjamin Lee
ee43c2ff4c
only link to one jemalloc build
Without setting JEMALLOC_OVERRIDE, we end up linking to two different
jemalloc builds. Once dynamically, as a transitive dependency through
rocksdb, and a second time to the static jemalloc that tikv-jemalloc-sys
builds.

This fixes dynamically-linked jemalloc builds, for the reasons described
in <https://github.com/girlbossceo/conduwuit/pull/400#issue-2316700200>.
2024-05-30 21:19:08 -07:00
Charles Hall
a25f2ec950
add conduit compat mode
This makes it possible to deploy Grapevine while using a database
originally created by Conduit, including leaving the admin bot user's
localpart the same as before.
2024-05-14 20:21:51 -07:00
Charles Hall
33e7a46b53
add a nixos module 2024-05-14 20:21:51 -07:00
Charles Hall
17eb354590
prevent bindgen and dependents from building twice
See also <https://crane.dev/faq/rebuilds-bindgen.html>.
2024-05-14 20:21:51 -07:00
Charles Hall
21a4b9e5a1
only set GRAPEVINE_VERSION_EXTRA for final build
This prevents us from needing to recompile the dependencies when that
environment variable changes, which generally changes on every commit,
which is far more frequently than the dependencies are actually changed.
2024-05-14 20:21:51 -07:00
Charles Hall
bbb1a6fea4
make it easy to configure cargo profiles from nix
This way you can easily build in debug mode with Nix.
2024-05-14 20:21:51 -07:00
Charles Hall
51f9650ca7
make it easy to configure cargo features from nix
Users of the nix package can now just use `.override` to choose what
features they want.

This also makes RocksDB automatically use jemalloc when Grapevine is
configured to use jemalloc.
2024-05-14 20:21:51 -07:00
Charles Hall
0f8d1a5ed7
factor out nix code into new files via makeScope
This makes the Nix code a lot easier to reason about.
2024-05-14 20:21:51 -07:00
Samuel Meenzen
425660472c
docs: build docs using mdBook 2024-03-16 20:01:15 -07:00
Charles Hall
6ae5143ff5
only listen on IPv6 since that's what conduit does 2023-07-21 12:12:37 -07:00
Jade
be9196430d fix nix readme to work with ipv6 2023-05-25 18:21:01 +00:00
Charles Hall
391beddaf4
fix nix docs
I made some silly copy paste errors while writing this...
2023-01-08 12:44:59 -08:00
Charles Hall
716f82db6d
add nix/nixos deployment documentation 2022-10-16 10:50:52 -07:00