pkgs/ranet: init at 0.11.0

This commit is contained in:
Lu Wang 2024-12-08 20:18:37 +08:00
parent bcdd4486fc
commit 898ce2046d
Signed by: rebmit
SSH key fingerprint: SHA256:3px8QV1zEerIrEWHaqtH5rR9kjetyRST5EipOPrd+bU
2 changed files with 46 additions and 3 deletions

View file

@ -1,17 +1,28 @@
{ rustPlatform, fetchFromGitHub, ... }: {
lib,
rustPlatform,
fetchFromGitHub,
...
}:
rustPlatform.buildRustPackage rec { rustPlatform.buildRustPackage rec {
name = "netns-proxy"; pname = "netns-proxy";
version = "unstable-2023-09-17";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "fooker"; owner = "fooker";
repo = "netns-proxy"; repo = "netns-proxy";
rev = "6d9ccbfde4375cd614735ea5f6ee5aba2b6cfd2b"; rev = "6d9ccbfde4375cd614735ea5f6ee5aba2b6cfd2b";
fetchSubmodules = false;
sha256 = "sha256-N+my6cTuA7yNoYxocpRiLNcy7OwrJLvO2cGLJGv8a/I="; sha256 = "sha256-N+my6cTuA7yNoYxocpRiLNcy7OwrJLvO2cGLJGv8a/I=";
}; };
cargoLock = { cargoLock = {
lockFile = src + /Cargo.lock; lockFile = src + /Cargo.lock;
}; };
meta = with lib; {
description = "A simple and slim proxy to forward ports from and into linux network namespaces";
homepage = "https://github.com/fooker/netns-proxy";
license = licenses.mit;
};
} }

32
pkgs/ranet/package.nix Normal file
View file

@ -0,0 +1,32 @@
{
lib,
rustPlatform,
fetchFromGitHub,
...
}:
rustPlatform.buildRustPackage rec {
pname = "ranet";
version = "0.11.0";
src = fetchFromGitHub {
owner = "NickCao";
repo = "ranet";
rev = "v${version}";
sha256 = "sha256-GB8FXnHzaM06MivfpYEFFIp4q0WfH3a7+jmoC3Tpwbs=";
};
cargoLock = {
lockFile = src + /Cargo.lock;
};
checkFlags = [
"--skip=address::test::remote"
];
meta = with lib; {
description = "Redundant array of networks";
homepage = "https://github.com/NickCao/ranet";
license = licenses.mit;
};
}