diff options
author | Luflosi <luflosi@luflosi.de> | 2022-07-24 20:49:05 +0200 |
---|---|---|
committer | Luflosi <luflosi@luflosi.de> | 2022-10-02 16:00:22 +0200 |
commit | eefaaf41d67ea28c3f70150958f6a29533dce709 (patch) | |
tree | 9989f3e3be7e87fd50b22882886e747389788c5a /pkgs/applications/networking/kubo-migrator/all-migrations.nix | |
parent | 7cb6b3251f51704a82a29a40de17db91ecd875c5 (diff) | |
download | nixpkgs-eefaaf41d67ea28c3f70150958f6a29533dce709.tar nixpkgs-eefaaf41d67ea28c3f70150958f6a29533dce709.tar.gz nixpkgs-eefaaf41d67ea28c3f70150958f6a29533dce709.tar.bz2 nixpkgs-eefaaf41d67ea28c3f70150958f6a29533dce709.tar.lz nixpkgs-eefaaf41d67ea28c3f70150958f6a29533dce709.tar.xz nixpkgs-eefaaf41d67ea28c3f70150958f6a29533dce709.tar.zst nixpkgs-eefaaf41d67ea28c3f70150958f6a29533dce709.zip |
kubo: rename from ipfs
Go-IPFS was renamed to Kubo in version 0.14.0, see https://github.com/ipfs/kubo/issues/8959.
Diffstat (limited to 'pkgs/applications/networking/kubo-migrator/all-migrations.nix')
-rw-r--r-- | pkgs/applications/networking/kubo-migrator/all-migrations.nix | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/pkgs/applications/networking/kubo-migrator/all-migrations.nix b/pkgs/applications/networking/kubo-migrator/all-migrations.nix new file mode 100644 index 00000000000..a9197c9db5f --- /dev/null +++ b/pkgs/applications/networking/kubo-migrator/all-migrations.nix @@ -0,0 +1,63 @@ +{ lib +, stdenv +, symlinkJoin +, buildGoModule +, kubo-migrator-unwrapped +}: + +# This package contains all the individual migrations in the bin directory. +# This is used by fs-repo-migrations and could also be used by Kubo itself +# when starting it like this: ipfs daemon --migrate + +let + fs-repo-common = pname: version: buildGoModule { + inherit pname version; + inherit (kubo-migrator-unwrapped) src; + sourceRoot = "source/${pname}"; + vendorSha256 = null; + doCheck = false; + meta = kubo-migrator-unwrapped.meta // { + mainProgram = pname; + description = "Individual migration for the filesystem repository of Kubo clients"; + }; + }; + + # Concatenation of the latest repo version and the version of that migration + version = "12.1.0.2"; + + fs-repo-11-to-12 = fs-repo-common "fs-repo-11-to-12" "1.0.2"; + fs-repo-10-to-11 = fs-repo-common "fs-repo-10-to-11" "1.0.1"; + fs-repo-9-to-10 = fs-repo-common "fs-repo-9-to-10" "1.0.1"; + fs-repo-8-to-9 = fs-repo-common "fs-repo-8-to-9" "1.0.1"; + fs-repo-7-to-8 = fs-repo-common "fs-repo-7-to-8" "1.0.1"; + fs-repo-6-to-7 = fs-repo-common "fs-repo-6-to-7" "1.0.1"; + fs-repo-5-to-6 = fs-repo-common "fs-repo-5-to-6" "1.0.1"; + fs-repo-4-to-5 = fs-repo-common "fs-repo-4-to-5" "1.0.1"; + fs-repo-3-to-4 = fs-repo-common "fs-repo-3-to-4" "1.0.1"; + fs-repo-2-to-3 = fs-repo-common "fs-repo-2-to-3" "1.0.1"; + fs-repo-1-to-2 = fs-repo-common "fs-repo-1-to-2" "1.0.1"; + fs-repo-0-to-1 = fs-repo-common "fs-repo-0-to-1" "1.0.1"; + + all-migrations = [ + fs-repo-11-to-12 + fs-repo-10-to-11 + fs-repo-9-to-10 + fs-repo-8-to-9 + fs-repo-7-to-8 + ] ++ lib.optional (!stdenv.isDarwin) # I didn't manage to fix this on macOS: + fs-repo-6-to-7 # gx/ipfs/QmSGRM5Udmy1jsFBr1Cawez7Lt7LZ3ZKA23GGVEsiEW6F3/eventfd/eventfd.go:27:32: undefined: syscall.SYS_EVENTFD2 + ++ [ + fs-repo-5-to-6 + fs-repo-4-to-5 + fs-repo-3-to-4 + fs-repo-2-to-3 + fs-repo-1-to-2 + fs-repo-0-to-1 + ]; + +in + +symlinkJoin { + name = "kubo-migrator-all-fs-repo-migrations-${version}"; + paths = all-migrations; +} |