about summary refs log tree commit diff
path: root/nixpkgs/pkgs/by-name/lx/lxd-to-incus/package.nix
blob: 0b9c34fb046d11bb7a68c1da471fd5675f85d1d2 (plain) (blame)
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
{ lib
, buildGoModule
, fetchFromGitHub
, gitUpdater
}:

buildGoModule rec {
  pname = "lxd-to-incus";
  version = "0.1";

  src = fetchFromGitHub {
    owner = "lxc";
    repo = "incus";
    # use commit which fixes 0.1 versioning, use tags for > 0.1
    rev = "253a06bd8506bf42628d32ccbca6409d051465ec";
    hash = "sha256-LXCTrZEDnFTJpqVH+gnG9HaV1wcvTFsVv2tAWabWYmg=";
  };

  modRoot = "cmd/lxd-to-incus";

  vendorHash = "sha256-Kk5sx8UYuip/qik5ez/pxi+DmzjkPIHNYUHVvBm9f9g=";

  # required for go-cowsql.
  CGO_LDFLAGS_ALLOW="(-Wl,-wrap,pthread_create)|(-Wl,-z,now)";

  passthru = {
    updateScript = gitUpdater {
      rev-prefix = "incus-";
    };
  };

  meta = {
    description = "LXD to Incus migration tool";
    homepage = "https://linuxcontainers.org/incus";
    license = lib.licenses.asl20;
    maintainers = with lib.maintainers; [ adamcstephens ];
    platforms = lib.platforms.linux;
  };
}