forked from wmde/wikibase-release-pipeline
-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
50 lines (47 loc) · 1.79 KB
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
flake-utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem (system:
let pkgs = nixpkgs.legacyPackages.${system};
in
with pkgs; {
devShell = with pkgs; mkShell {
buildInputs = [
docker-client
gnumake
envsubst
];
shellHook = ''
${pkgs.figlet}/bin/figlet "wbsrpl dev shell"
echo "Wikibase Release Pipeline"
echo
echo "Build Commands:"
echo "# Build all wikibase suite components docker images"
echo "$ ./build.sh"
echo "# Build only the mediawiki/wikibase containers"
echo "$ ./build.sh wikibase"
echo "# Build only the query service container and save the docker image to a tarball"
echo "$ ./build.sh --save-image wdqs"
echo "# Build the wdqs-frontend container and extract a standalone tarball from the webroot"
echo "$ ./build.sh --extract-tarball wdqs-frontend"
echo "# Build the wdqs container without using Dockers cache"
echo "$ ./build.sh --no-cache wdqs"
echo
echo "Test Commands:"
echo "$ ./test.sh"
echo "$ ./test.sh repo"
echo "$ ./test.sh repo --spec specs/repo/special-item.ts"
echo "$ ./test.sh upgrade WMDE9"
echo
echo "Example Instance Commands:"
echo "$ docker compose \\"
echo " -f ./example/docker-compose.yml \\"
echo " -f ./example/docker-compose.extra.yml \\"
echo " --env-file ./example/template.env up"
'';
};
});
}