Our Personal Data Server from scratch!
tranquil.farm
oauth
atproto
pds
rust
postgresql
objectstorage
fun
1{
2 lib,
3 rustPlatform,
4 pkg-config,
5 openssl,
6}: let
7 toml = (lib.importTOML ./Cargo.toml).workspace.package;
8in rustPlatform.buildRustPackage {
9 pname = "tranquil-pds";
10 inherit (toml) version;
11
12 src = lib.fileset.toSource {
13 root = ./.;
14 fileset = lib.fileset.intersection (lib.fileset.fromSource (lib.sources.cleanSource ./.)) (
15 lib.fileset.unions [
16 ./Cargo.toml
17 ./Cargo.lock
18 ./crates
19 ./.sqlx
20 ./migrations
21 ]
22 );
23 };
24
25 nativeBuildInputs = [
26 pkg-config
27 ];
28
29 buildInputs = [
30 openssl
31 ];
32
33 cargoLock.lockFile = ./Cargo.lock;
34
35 doCheck = false;
36
37 meta = {
38 license = lib.licenses.agpl3Plus;
39 mainProgram = "tranquil-pds";
40 };
41}