83627f9931
GitOrigin-RevId: 2893f56de08021cffd9b6b6dfc70fd9ccd51eb60
38 lines
1.2 KiB
Nix
38 lines
1.2 KiB
Nix
{ lib, openssl, pkg-config, fetchFromGitHub, rustPlatform }:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
pname = "afterburn";
|
|
version = "5.6.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "coreos";
|
|
repo = "afterburn";
|
|
rev = "v${version}";
|
|
sha256 = "sha256-IAYQJviSQHKeayI0uAEbXX+vQxfAbMOqP2fH+2VPamQ=";
|
|
};
|
|
|
|
cargoHash = "sha256-BJ8WV8FcRrwPHhCY2GiOWDP72/T3K9eJIrPeoIa+9Sk=";
|
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
buildInputs = [ openssl ];
|
|
|
|
postPatch = ''
|
|
substituteInPlace ./systemd/afterburn-checkin.service --replace /usr/bin $out/bin
|
|
substituteInPlace ./systemd/afterburn-firstboot-checkin.service --replace /usr/bin $out/bin
|
|
substituteInPlace ./systemd/afterburn-sshkeys@.service.in --replace /usr/bin $out/bin
|
|
substituteInPlace ./systemd/afterburn.service --replace /usr/bin $out/bin
|
|
'';
|
|
|
|
postInstall = ''
|
|
DEFAULT_INSTANCE=root PREFIX= DESTDIR=$out make install-units
|
|
'';
|
|
|
|
meta = with lib; {
|
|
homepage = "https://github.com/coreos/ignition";
|
|
description = "One-shot cloud provider agent";
|
|
license = licenses.asl20;
|
|
maintainers = [ maintainers.arianvp ];
|
|
platforms = platforms.linux;
|
|
mainProgram = "afterburn";
|
|
};
|
|
}
|