0
0
Fork 0
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-07-13 13:40:28 +03:00

Merge pull request #85604 from adisbladis/podman-module

nixos/virtualisation.podman: Init module
This commit is contained in:
adisbladis 2020-04-21 23:48:48 +02:00 committed by GitHub
commit 2d91da909e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 1082 additions and 812 deletions

View file

@ -248,6 +248,7 @@ in
php = handleTest ./php {};
plasma5 = handleTest ./plasma5.nix {};
plotinus = handleTest ./plotinus.nix {};
podman = handleTest ./podman.nix {};
postgis = handleTest ./postgis.nix {};
postgresql = handleTest ./postgresql.nix {};
postgresql-wal-receiver = handleTest ./postgresql-wal-receiver.nix {};

30
nixos/tests/podman.nix Normal file
View file

@ -0,0 +1,30 @@
# This test runs podman and checks if simple container starts
import ./make-test-python.nix (
{ pkgs, lib, ... }: {
name = "podman";
meta = {
maintainers = lib.teams.podman.members;
};
nodes = {
podman =
{ pkgs, ... }:
{
virtualisation.podman.enable = true;
};
};
testScript = ''
start_all()
podman.wait_for_unit("sockets.target")
podman.succeed("tar cv --files-from /dev/null | podman import - scratchimg")
podman.succeed(
"podman run -d --name=sleeping -v /nix/store:/nix/store -v /run/current-system/sw/bin:/bin scratchimg /bin/sleep 10"
)
podman.succeed("podman ps | grep sleeping")
podman.succeed("podman stop sleeping")
'';
}
)