Commit 22702776 authored by Valentin Reis's avatar Valentin Reis

singularity things.

parent 22e870cd
No preview for this file type
......@@ -38,6 +38,11 @@ let
environment.argo.root-access.enable=true;
environment.argo.ssh-config.enable=true;
environment.argo.singularity ={
enable = true;
package = argopkgs.singularity;
};
environment.variables.TERM = "xterm";
i18n.defaultLocale = "en_US.UTF-8";
......
......@@ -4,4 +4,5 @@
./ssh-config
./provider-tacc
./provider-openspace
./singularity
]
{ config, pkgs, lib, ... }:
with lib;
let
cfg = config.environment.argo.singularity;
singularity = cfg.package.overrideAttrs (attrs : {
installPhase = attrs.installPhase + ''
mv $bin/libexec/singularity/bin/starter-suid $bin/libexec/singularity/bin/starter-suid.orig
ln -s /run/wrappers/bin/singularity-suid $bin/libexec/singularity/bin/starter-suid
'';
});
in {
options.environment.argo.singularity = {
enable = mkEnableOption "Singularity";
package = mkOption {
type = types.path;
description = "The singularity package";
};
};
config = mkIf cfg.enable {
environment.systemPackages = [ singularity ];
security.wrappers.singularity-suid.source = "${singularity}/libexec/singularity/bin/starter-suid.orig";
systemd.tmpfiles.rules = [
"d /var/singularity/mnt/session 0770 root root -"
"d /var/singularity/mnt/final 0770 root root -"
"d /var/singularity/mnt/overlay 0770 root root -"
"d /var/singularity/mnt/container 0770 root root -"
"d /var/singularity/mnt/source 0770 root root -"
];
};
}
#!/usr/bin/env bash
nix-prefetch-git https://github.com/nixos/nixpkgs-channels.git refs/heads/nixos-unstable > nixpkgs-unstable.json
nix-prefetch-git https://github.com/nixos/nixpkgs-channels.git refs/heads/nixos-unstable > nixpkgs-unstable-nixos-ci.json
......@@ -54,7 +54,7 @@ let
# library of nix expressions
argolib = import ../lib/utils.nix;
flatcc = callPackage ./flatcc {};
singularity = bleeding.singularity;
# Argo components (source overridabel via argument)
aml = callPackage ./aml {
src=aml-src;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment