+17
.tangled/workflows/build.yml
+17
.tangled/workflows/build.yml
+1
-2
LICENSE
+1
-2
LICENSE
···
1
1
MIT License
2
2
3
-
Copyright (c) 2018 Francesco Gazzetta
3
+
Copyright (c) 2025 atproto-nix.org
4
4
5
5
Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
of this software and associated documentation files (the "Software"), to deal
···
19
19
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
20
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
21
SOFTWARE.
22
-
+6
-5
default.nix
+6
-5
default.nix
···
6
6
# commands such as:
7
7
# nix-build -A mypackage
8
8
9
-
{ pkgs ? import <nixpkgs> { } }:
9
+
{ pkgs ? import <nixpkgs> { }, craneLib ? null, buildYarnPackage ? pkgs.buildYarnPackage }:
10
10
11
11
{
12
12
# The `lib`, `modules`, and `overlays` names are special
···
14
14
modules = import ./modules; # NixOS modules
15
15
overlays = import ./overlays; # nixpkgs overlays
16
16
17
-
example-package = pkgs.callPackage ./pkgs/example-package { };
18
-
# some-qt5-package = pkgs.libsForQt5.callPackage ./pkgs/some-qt5-package { };
19
-
# ...
20
-
}
17
+
bluesky = pkgs.callPackage ./pkgs/bluesky {
18
+
buildGoModule = pkgs.buildGoModule;
19
+
fetchFromGitHub = pkgs.fetchFromGitHub;
20
+
};
21
+
}
+185
-4
flake.lock
+185
-4
flake.lock
···
1
1
{
2
2
"nodes": {
3
+
"crane": {
4
+
"locked": {
5
+
"lastModified": 1758758545,
6
+
"narHash": "sha256-NU5WaEdfwF6i8faJ2Yh+jcK9vVFrofLcwlD/mP65JrI=",
7
+
"owner": "ipetkov",
8
+
"repo": "crane",
9
+
"rev": "95d528a5f54eaba0d12102249ce42f4d01f4e364",
10
+
"type": "github"
11
+
},
12
+
"original": {
13
+
"owner": "ipetkov",
14
+
"repo": "crane",
15
+
"type": "github"
16
+
}
17
+
},
18
+
"flake-utils": {
19
+
"inputs": {
20
+
"systems": "systems"
21
+
},
22
+
"locked": {
23
+
"lastModified": 1731533236,
24
+
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
25
+
"owner": "numtide",
26
+
"repo": "flake-utils",
27
+
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
28
+
"type": "github"
29
+
},
30
+
"original": {
31
+
"owner": "numtide",
32
+
"repo": "flake-utils",
33
+
"type": "github"
34
+
}
35
+
},
36
+
"flake-utils_2": {
37
+
"inputs": {
38
+
"systems": "systems_2"
39
+
},
40
+
"locked": {
41
+
"lastModified": 1731533236,
42
+
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
43
+
"owner": "numtide",
44
+
"repo": "flake-utils",
45
+
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
46
+
"type": "github"
47
+
},
48
+
"original": {
49
+
"owner": "numtide",
50
+
"repo": "flake-utils",
51
+
"type": "github"
52
+
}
53
+
},
54
+
"ixx": {
55
+
"inputs": {
56
+
"flake-utils": [
57
+
"search",
58
+
"flake-utils"
59
+
],
60
+
"nixpkgs": [
61
+
"search",
62
+
"nixpkgs"
63
+
]
64
+
},
65
+
"locked": {
66
+
"lastModified": 1754860581,
67
+
"narHash": "sha256-EM0IE63OHxXCOpDHXaTyHIOk2cNvMCGPqLt/IdtVxgk=",
68
+
"owner": "NuschtOS",
69
+
"repo": "ixx",
70
+
"rev": "babfe85a876162c4acc9ab6fb4483df88fa1f281",
71
+
"type": "github"
72
+
},
73
+
"original": {
74
+
"owner": "NuschtOS",
75
+
"ref": "v0.1.1",
76
+
"repo": "ixx",
77
+
"type": "github"
78
+
}
79
+
},
3
80
"nixpkgs": {
4
81
"locked": {
5
-
"lastModified": 1712449641,
6
-
"narHash": "sha256-U9DDWMexN6o5Td2DznEgguh8TRIUnIl9levmit43GcI=",
82
+
"lastModified": 1758446476,
83
+
"narHash": "sha256-5rdAi7CTvM/kSs6fHe1bREIva5W3TbImsto+dxG4mBo=",
84
+
"owner": "NixOS",
85
+
"repo": "nixpkgs",
86
+
"rev": "a1f79a1770d05af18111fbbe2a3ab2c42c0f6cd0",
87
+
"type": "github"
88
+
},
89
+
"original": {
90
+
"owner": "NixOS",
91
+
"ref": "nixpkgs-unstable",
92
+
"repo": "nixpkgs",
93
+
"type": "github"
94
+
}
95
+
},
96
+
"nixpkgs_2": {
97
+
"locked": {
98
+
"lastModified": 1744536153,
99
+
"narHash": "sha256-awS2zRgF4uTwrOKwwiJcByDzDOdo3Q1rPZbiHQg/N38=",
7
100
"owner": "NixOS",
8
101
"repo": "nixpkgs",
9
-
"rev": "600b15aea1b36eeb43833a50b0e96579147099ff",
102
+
"rev": "18dd725c29603f582cf1900e0d25f9f1063dbf11",
10
103
"type": "github"
11
104
},
12
105
"original": {
···
16
109
"type": "github"
17
110
}
18
111
},
112
+
"nixpkgs_3": {
113
+
"locked": {
114
+
"lastModified": 1758035966,
115
+
"narHash": "sha256-qqIJ3yxPiB0ZQTT9//nFGQYn8X/PBoJbofA7hRKZnmE=",
116
+
"owner": "NixOS",
117
+
"repo": "nixpkgs",
118
+
"rev": "8d4ddb19d03c65a36ad8d189d001dc32ffb0306b",
119
+
"type": "github"
120
+
},
121
+
"original": {
122
+
"owner": "NixOS",
123
+
"ref": "nixos-unstable",
124
+
"repo": "nixpkgs",
125
+
"type": "github"
126
+
}
127
+
},
19
128
"root": {
20
129
"inputs": {
21
-
"nixpkgs": "nixpkgs"
130
+
"crane": "crane",
131
+
"flake-utils": "flake-utils",
132
+
"nixpkgs": "nixpkgs",
133
+
"rust-overlay": "rust-overlay",
134
+
"search": "search"
135
+
}
136
+
},
137
+
"rust-overlay": {
138
+
"inputs": {
139
+
"nixpkgs": "nixpkgs_2"
140
+
},
141
+
"locked": {
142
+
"lastModified": 1758767687,
143
+
"narHash": "sha256-znUulOqcL/Kkdr7CkyIi8Z1pTGXpi54Xg2FmlyJmv4A=",
144
+
"owner": "oxalica",
145
+
"repo": "rust-overlay",
146
+
"rev": "b8bcc09d4f627f4e325408f6e7a85c3ac31f0eeb",
147
+
"type": "github"
148
+
},
149
+
"original": {
150
+
"owner": "oxalica",
151
+
"repo": "rust-overlay",
152
+
"type": "github"
153
+
}
154
+
},
155
+
"search": {
156
+
"inputs": {
157
+
"flake-utils": "flake-utils_2",
158
+
"ixx": "ixx",
159
+
"nixpkgs": "nixpkgs_3"
160
+
},
161
+
"locked": {
162
+
"lastModified": 1758662783,
163
+
"narHash": "sha256-igrxT+/MnmcftPOHEb+XDwAMq3Xg1Xy7kVYQaHhPlAg=",
164
+
"owner": "NuschtOS",
165
+
"repo": "search",
166
+
"rev": "7d4c0fc4ffe3bd64e5630417162e9e04e64b27a4",
167
+
"type": "github"
168
+
},
169
+
"original": {
170
+
"owner": "NuschtOS",
171
+
"repo": "search",
172
+
"type": "github"
173
+
}
174
+
},
175
+
"systems": {
176
+
"locked": {
177
+
"lastModified": 1681028828,
178
+
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
179
+
"owner": "nix-systems",
180
+
"repo": "default",
181
+
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
182
+
"type": "github"
183
+
},
184
+
"original": {
185
+
"owner": "nix-systems",
186
+
"repo": "default",
187
+
"type": "github"
188
+
}
189
+
},
190
+
"systems_2": {
191
+
"locked": {
192
+
"lastModified": 1681028828,
193
+
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
194
+
"owner": "nix-systems",
195
+
"repo": "default",
196
+
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
197
+
"type": "github"
198
+
},
199
+
"original": {
200
+
"owner": "nix-systems",
201
+
"repo": "default",
202
+
"type": "github"
22
203
}
23
204
}
24
205
},
+49
-12
flake.nix
+49
-12
flake.nix
···
1
1
{
2
-
description = "My personal NUR repository";
3
-
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
4
-
outputs = { self, nixpkgs }:
5
-
let
6
-
forAllSystems = nixpkgs.lib.genAttrs nixpkgs.lib.systems.flakeExposed;
7
-
in
2
+
description = "ATproto NUR repository";
3
+
inputs = {
4
+
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
5
+
flake-utils.url = "github:numtide/flake-utils";
6
+
crane.url = "github:ipetkov/crane";
7
+
rust-overlay.url = "github:oxalica/rust-overlay";
8
+
search.url = "github:NuschtOS/search";
9
+
};
10
+
11
+
outputs =
8
12
{
9
-
legacyPackages = forAllSystems (system: import ./default.nix {
10
-
pkgs = import nixpkgs { inherit system; };
11
-
});
12
-
packages = forAllSystems (system: nixpkgs.lib.filterAttrs (_: v: nixpkgs.lib.isDerivation v) self.legacyPackages.${system});
13
-
};
14
-
}
13
+
self,
14
+
nixpkgs,
15
+
flake-utils,
16
+
crane,
17
+
rust-overlay,
18
+
search,
19
+
...
20
+
}:
21
+
flake-utils.lib.eachDefaultSystem (
22
+
system:
23
+
let
24
+
overlays = [ (import rust-overlay) ];
25
+
pkgs = import nixpkgs {
26
+
inherit system overlays;
27
+
};
28
+
rustVersion = pkgs.rust-bin.stable.latest.default;
29
+
craneLib = (crane.mkLib pkgs).overrideToolchain rustVersion;
30
+
31
+
nurPackages = import ./default.nix {
32
+
inherit pkgs craneLib;
33
+
};
34
+
packages = pkgs.lib.filterAttrs (n: v: pkgs.lib.isDerivation v) nurPackages;
35
+
in
36
+
{
37
+
packages = packages // {
38
+
default = packages.bluesky;
39
+
search = search.packages.${system}.default;
40
+
};
41
+
legacyPackages = packages;
42
+
nixosModules = {
43
+
nur-atproto = import ./modules;
44
+
search = search.nixosModules.default;
45
+
};
46
+
devShells.default = pkgs.mkShell {
47
+
# todo
48
+
};
49
+
}
50
+
);
51
+
}
+45
modules/bluesky/beemo.nix
+45
modules/bluesky/beemo.nix
···
1
+
{ lib, config, pkgs, ... }:
2
+
3
+
with lib;
4
+
5
+
let
6
+
cfg = config.services.beemo;
7
+
in
8
+
{
9
+
options.services.beemo = {
10
+
enable = mkEnableOption "beemo";
11
+
12
+
package = mkOption {
13
+
type = types.package;
14
+
default = pkgs.bluesky;
15
+
description = "The beemo package to use.";
16
+
};
17
+
18
+
slackWebhookUrl = mkOption {
19
+
type = types.str;
20
+
description = "Slack webhook URL.";
21
+
};
22
+
};
23
+
24
+
config = mkIf cfg.enable {
25
+
systemd.services.beemo-notify-reports = {
26
+
description = "beemo notify-reports service";
27
+
after = [ "network.target" ];
28
+
wantedBy = [ "multi-user.target" ];
29
+
serviceConfig = {
30
+
ExecStart = "${cfg.package}/bin/beemo notify-reports --slack-webhook-url ${cfg.slackWebhookUrl}";
31
+
Restart = "on-failure";
32
+
};
33
+
};
34
+
35
+
systemd.services.beemo-notify-mentions = {
36
+
description = "beemo notify-mentions service";
37
+
after = [ "network.target" ];
38
+
wantedBy = [ "multi-user.target" ];
39
+
serviceConfig = {
40
+
ExecStart = "${cfg.package}/bin/beemo notify-mentions --slack-webhook-url ${cfg.slackWebhookUrl}";
41
+
Restart = "on-failure";
42
+
};
43
+
};
44
+
};
45
+
}
+30
modules/bluesky/bigsky.nix
+30
modules/bluesky/bigsky.nix
···
1
+
{ lib, config, pkgs, ... }:
2
+
3
+
with lib;
4
+
5
+
let
6
+
cfg = config.services.bigsky;
7
+
in
8
+
{
9
+
options.services.bigsky = {
10
+
enable = mkEnableOption "bigsky";
11
+
12
+
package = mkOption {
13
+
type = types.package;
14
+
default = pkgs.bluesky;
15
+
description = "The bigsky package to use.";
16
+
};
17
+
};
18
+
19
+
config = mkIf cfg.enable {
20
+
systemd.services.bigsky = {
21
+
description = "bigsky service";
22
+
after = [ "network.target" ];
23
+
wantedBy = [ "multi-user.target" ];
24
+
serviceConfig = {
25
+
ExecStart = "${cfg.package}/bin/bigsky";
26
+
Restart = "on-failure";
27
+
};
28
+
};
29
+
};
30
+
}
+12
modules/bluesky/default.nix
+12
modules/bluesky/default.nix
+95
modules/bluesky/hepa.nix
+95
modules/bluesky/hepa.nix
···
1
+
{ lib, config, pkgs, ... }:
2
+
3
+
with lib;
4
+
5
+
let
6
+
cfg = config.services.hepa;
7
+
in
8
+
{
9
+
options.services.hepa = {
10
+
enable = mkEnableOption "hepa";
11
+
12
+
package = mkOption {
13
+
type = types.package;
14
+
default = pkgs.bluesky;
15
+
description = "The hepa package to use.";
16
+
};
17
+
18
+
atpRelayHost = mkOption {
19
+
type = types.str;
20
+
default = "wss://bsky.network";
21
+
description = "ATP relay host.";
22
+
};
23
+
24
+
atpPlcHost = mkOption {
25
+
type = types.str;
26
+
default = "https://plc.directory";
27
+
description = "ATP PLC host.";
28
+
};
29
+
30
+
atpBskyHost = mkOption {
31
+
type = types.str;
32
+
default = "https://public.api.bsky.app";
33
+
description = "ATP bsky host.";
34
+
};
35
+
36
+
atpOzoneHost = mkOption {
37
+
type = types.str;
38
+
default = "https://mod.bsky.app";
39
+
description = "ATP ozone host.";
40
+
};
41
+
42
+
ozoneDid = mkOption {
43
+
type = types.str;
44
+
description = "Ozone DID.";
45
+
};
46
+
47
+
ozoneAdminToken = mkOption {
48
+
type = types.str;
49
+
description = "Ozone admin token.";
50
+
};
51
+
52
+
atpPdsHost = mkOption {
53
+
type = types.str;
54
+
default = "https://bsky.social";
55
+
description = "ATP PDS host.";
56
+
};
57
+
58
+
pdsAdminToken = mkOption {
59
+
type = types.str;
60
+
description = "PDS admin token.";
61
+
};
62
+
63
+
redisUrl = mkOption {
64
+
type = types.str;
65
+
description = "Redis URL.";
66
+
};
67
+
68
+
hiveaiApiToken = mkOption {
69
+
type = types.str;
70
+
description = "Hive AI API token.";
71
+
};
72
+
73
+
abyssHost = mkOption {
74
+
type = types.str;
75
+
description = "Abyss host.";
76
+
};
77
+
78
+
abyssPassword = mkOption {
79
+
type = types.str;
80
+
description = "Abyss password.";
81
+
};
82
+
};
83
+
84
+
config = mkIf cfg.enable {
85
+
systemd.services.hepa = {
86
+
description = "hepa service";
87
+
after = [ "network.target" ];
88
+
wantedBy = [ "multi-user.target" ];
89
+
serviceConfig = {
90
+
ExecStart = "${cfg.package}/bin/hepa run --atp-relay-host ${cfg.atpRelayHost} --atp-plc-host ${cfg.atpPlcHost} --atp-bsky-host ${cfg.atpBskyHost} --atp-ozone-host ${cfg.atpOzoneHost} --ozone-did ${cfg.ozoneDid} --ozone-admin-token ${cfg.ozoneAdminToken} --atp-pds-host ${cfg.atpPdsHost} --pds-admin-token ${cfg.pdsAdminToken} --redis-url ${cfg.redisUrl} --hiveai-api-token ${cfg.hiveaiApiToken} --abyss-host ${cfg.abyssHost} --abyss-password ${cfg.abyssPassword}";
91
+
Restart = "on-failure";
92
+
};
93
+
};
94
+
};
95
+
}
+83
modules/bluesky/palomar.nix
+83
modules/bluesky/palomar.nix
···
1
+
{ lib, config, pkgs, ... }:
2
+
3
+
with lib;
4
+
5
+
let
6
+
cfg = config.services.palomar;
7
+
in
8
+
{
9
+
options.services.palomar = {
10
+
enable = mkEnableOption "palomar";
11
+
12
+
package = mkOption {
13
+
type = types.package;
14
+
default = pkgs.bluesky;
15
+
description = "The palomar package to use.";
16
+
};
17
+
18
+
elasticCertFile = mkOption {
19
+
type = types.str;
20
+
description = "Elasticsearch cert file.";
21
+
};
22
+
23
+
elasticInsecureSsl = mkOption {
24
+
type = types.bool;
25
+
default = false;
26
+
description = "Elasticsearch insecure SSL.";
27
+
};
28
+
29
+
elasticUsername = mkOption {
30
+
type = types.str;
31
+
default = "admin";
32
+
description = "Elasticsearch username.";
33
+
};
34
+
35
+
elasticPassword = mkOption {
36
+
type = types.str;
37
+
default = "0penSearch-Pal0mar";
38
+
description = "Elasticsearch password.";
39
+
};
40
+
41
+
elasticHosts = mkOption {
42
+
type = types.str;
43
+
default = "http://localhost:9200";
44
+
description = "Elasticsearch hosts.";
45
+
};
46
+
47
+
esPostIndex = mkOption {
48
+
type = types.str;
49
+
default = "palomar_post";
50
+
description = "Elasticsearch post index.";
51
+
};
52
+
53
+
esProfileIndex = mkOption {
54
+
type = types.str;
55
+
default = "palomar_profile";
56
+
description = "Elasticsearch profile index.";
57
+
};
58
+
59
+
atpRelayHost = mkOption {
60
+
type = types.str;
61
+
default = "wss://bsky.network";
62
+
description = "ATP relay host.";
63
+
};
64
+
65
+
atpPlcHost = mkOption {
66
+
type = types.str;
67
+
default = "https://plc.directory";
68
+
description = "ATP PLC host.";
69
+
};
70
+
};
71
+
72
+
config = mkIf cfg.enable {
73
+
systemd.services.palomar = {
74
+
description = "palomar service";
75
+
after = [ "network.target" ];
76
+
wantedBy = [ "multi-user.target" ];
77
+
serviceConfig = {
78
+
ExecStart = "${cfg.package}/bin/palomar run --elastic-cert-file ${cfg.elasticCertFile} --elastic-insecure-ssl ${toString cfg.elasticInsecureSsl} --elastic-username ${cfg.elasticUsername} --elastic-password ${cfg.elasticPassword} --elastic-hosts ${cfg.elasticHosts} --es-post-index ${cfg.esPostIndex} --es-profile-index ${cfg.esProfileIndex} --atp-relay-host ${cfg.atpRelayHost} --atp-plc-host ${cfg.atpPlcHost}";
79
+
Restart = "on-failure";
80
+
};
81
+
};
82
+
};
83
+
}
+41
modules/bluesky/relay.nix
+41
modules/bluesky/relay.nix
···
1
+
{ lib, config, pkgs, ... }:
2
+
3
+
with lib;
4
+
5
+
let
6
+
cfg = config.services.relay;
7
+
in
8
+
{
9
+
options.services.relay = {
10
+
enable = mkEnableOption "relay";
11
+
12
+
package = mkOption {
13
+
type = types.package;
14
+
default = pkgs.bluesky;
15
+
description = "The relay package to use.";
16
+
};
17
+
18
+
adminPassword = mkOption {
19
+
type = types.str;
20
+
description = "Admin password for the relay.";
21
+
};
22
+
23
+
plcHost = mkOption {
24
+
type = types.str;
25
+
default = "https://plc.directory";
26
+
description = "PLC host for the relay.";
27
+
};
28
+
};
29
+
30
+
config = mkIf cfg.enable {
31
+
systemd.services.relay = {
32
+
description = "relay service";
33
+
after = [ "network.target" ];
34
+
wantedBy = [ "multi-user.target" ];
35
+
serviceConfig = {
36
+
ExecStart = "${cfg.package}/bin/relay serve --admin-password ${cfg.adminPassword} --plc-host ${cfg.plcHost}";
37
+
Restart = "on-failure";
38
+
};
39
+
};
40
+
};
41
+
}
+61
modules/bluesky/sonar.nix
+61
modules/bluesky/sonar.nix
···
1
+
{ lib, config, pkgs, ... }:
2
+
3
+
with lib;
4
+
5
+
let
6
+
cfg = config.services.sonar;
7
+
in
8
+
{
9
+
options.services.sonar = {
10
+
enable = mkEnableOption "sonar";
11
+
12
+
package = mkOption {
13
+
type = types.package;
14
+
default = pkgs.bluesky;
15
+
description = "The sonar package to use.";
16
+
};
17
+
18
+
wsUrl = mkOption {
19
+
type = types.str;
20
+
default = "wss://bsky.network/xrpc/com.atproto.sync.subscribeRepos";
21
+
description = "Websocket URL.";
22
+
};
23
+
24
+
logLevel = mkOption {
25
+
type = types.str;
26
+
default = "info";
27
+
description = "Log level.";
28
+
};
29
+
30
+
port = mkOption {
31
+
type = types.port;
32
+
default = 8345;
33
+
description = "Metrics server port.";
34
+
};
35
+
36
+
maxQueueSize = mkOption {
37
+
type = types.int;
38
+
default = 10;
39
+
description = "Max queue size.";
40
+
};
41
+
42
+
cursorFile = mkOption {
43
+
type = types.str;
44
+
default = "/var/lib/sonar/cursor.json";
45
+
description = "Cursor file.";
46
+
};
47
+
};
48
+
49
+
config = mkIf cfg.enable {
50
+
systemd.services.sonar = {
51
+
description = "sonar service";
52
+
after = [ "network.target" ];
53
+
wantedBy = [ "multi-user.target" ];
54
+
serviceConfig = {
55
+
ExecStart = "${cfg.package}/bin/sonar --ws-url ${cfg.wsUrl} --log-level ${cfg.logLevel} --port ${toString cfg.port} --max-queue-size ${toString cfg.maxQueueSize} --cursor-file ${cfg.cursorFile}";
56
+
Restart = "on-failure";
57
+
StateDirectory = "sonar";
58
+
};
59
+
};
60
+
};
61
+
}
+4
-4
modules/default.nix
+4
-4
modules/default.nix
+1
-4
overlays/default.nix
+1
-4
overlays/default.nix
-9
pkgs/blacksky/default.nix
-9
pkgs/blacksky/default.nix
+41
-7
pkgs/bluesky/default.nix
+41
-7
pkgs/bluesky/default.nix
···
1
-
{ stdenv }:
1
+
{ lib, buildGoModule, fetchFromGitHub }:
2
2
3
-
stdenv.mkDerivation rec {
4
-
name = "example-package-${version}";
5
-
version = "1.0";
6
-
src = ./.;
7
-
buildPhase = "echo echo Hello World > example";
8
-
installPhase = "install -Dm755 example $out";
3
+
buildGoModule rec {
4
+
pname = "indigo";
5
+
version = "unstable-2023-09-24";
6
+
7
+
src = fetchFromGitHub {
8
+
owner = "bluesky-social";
9
+
repo = "indigo";
10
+
rev = "b4dd6383c76ffe205afe5407a027bb90a7461b12";
11
+
sha256 = "sha256-e0Y/k1RBnFg8Z9VT7rxuZeyvJo2MZIOHQJbo9prTaoQ=";
12
+
};
13
+
14
+
vendorHash = "sha256-7mYvgvR0tZdEnUgUYzKv6d2QyeXXnrFgVwY8/4UM3oU=";
15
+
16
+
subPackages = [
17
+
"cmd/goat"
18
+
"cmd/gosky"
19
+
"cmd/bigsky"
20
+
"cmd/relay"
21
+
"cmd/beemo"
22
+
"cmd/lexgen"
23
+
"cmd/stress"
24
+
"cmd/fakermaker"
25
+
"cmd/hepa"
26
+
"cmd/supercollider"
27
+
"cmd/sonar"
28
+
"cmd/palomar"
29
+
];
30
+
31
+
buildFlags = [ "-mod=vendor" ];
32
+
33
+
preBuild = ''
34
+
export HOME=$TMPDIR
35
+
'';
36
+
37
+
meta = with lib; {
38
+
description = "Go source code for Bluesky's atproto services";
39
+
homepage = "https://github.com/bluesky-social/indigo";
40
+
license = licenses.mit;
41
+
maintainers = with maintainers; [ ];
42
+
};
9
43
}