Merge branch 'staging' (older one)
Hydra seems OK-ish, except that some aarch64 jobs need restarting after qt4 timing out for the first time: https://hydra.nixos.org/eval/1412641?compare=1412561
This commit is contained in:
@@ -41,7 +41,6 @@ let
|
||||
generators = callLibs ./generators.nix;
|
||||
misc = callLibs ./deprecated.nix;
|
||||
# domain-specific
|
||||
sandbox = callLibs ./sandbox.nix;
|
||||
fetchers = callLibs ./fetchers.nix;
|
||||
|
||||
# Eval-time filesystem handling
|
||||
|
||||
@@ -208,6 +208,7 @@
|
||||
eqyiel = "Ruben Maher <r@rkm.id.au>";
|
||||
ericbmerritt = "Eric Merritt <eric@afiniate.com>";
|
||||
ericsagnes = "Eric Sagnes <eric.sagnes@gmail.com>";
|
||||
ericson2314 = "John Ericson <John.Ericson@Obsidian.Systems>";
|
||||
erictapen = "Justin Humm <justin.humm@posteo.de>";
|
||||
erikryb = "Erik Rybakken <erik.rybakken@math.ntnu.no>";
|
||||
ertes = "Ertugrul Söylemez <esz@posteo.de>";
|
||||
|
||||
@@ -1,48 +0,0 @@
|
||||
{ lib }:
|
||||
with lib.strings;
|
||||
|
||||
/* Helpers for creating lisp S-exprs for the Apple sandbox
|
||||
|
||||
lib.sandbox.allowFileRead [ "/usr/bin/file" ];
|
||||
# => "(allow file-read* (literal \"/usr/bin/file\"))";
|
||||
|
||||
lib.sandbox.allowFileRead {
|
||||
literal = [ "/usr/bin/file" ];
|
||||
subpath = [ "/usr/lib/system" ];
|
||||
}
|
||||
# => "(allow file-read* (literal \"/usr/bin/file\") (subpath \"/usr/lib/system\"))"
|
||||
*/
|
||||
|
||||
let
|
||||
|
||||
sexp = tokens: "(" + builtins.concatStringsSep " " tokens + ")";
|
||||
generateFileList = files:
|
||||
if builtins.isList files
|
||||
then concatMapStringsSep " " (x: sexp [ "literal" ''"${x}"'' ]) files
|
||||
else if builtins.isString files
|
||||
then generateFileList [ files ]
|
||||
else concatStringsSep " " (
|
||||
(map (x: sexp [ "literal" ''"${x}"'' ]) (files.literal or [])) ++
|
||||
(map (x: sexp [ "subpath" ''"${x}"'' ]) (files.subpath or []))
|
||||
);
|
||||
applyToFiles = f: act: files: f "${act} ${generateFileList files}";
|
||||
genActions = actionName: let
|
||||
action = feature: sexp [ actionName feature ];
|
||||
self = {
|
||||
"${actionName}" = action;
|
||||
"${actionName}File" = applyToFiles action "file*";
|
||||
"${actionName}FileRead" = applyToFiles action "file-read*";
|
||||
"${actionName}FileReadMetadata" = applyToFiles action "file-read-metadata";
|
||||
"${actionName}DirectoryList" = self."${actionName}FileReadMetadata";
|
||||
"${actionName}FileWrite" = applyToFiles action "file-write*";
|
||||
"${actionName}FileWriteMetadata" = applyToFiles action "file-write-metadata";
|
||||
};
|
||||
in self;
|
||||
|
||||
in
|
||||
|
||||
genActions "allow" // genActions "deny" // {
|
||||
importProfile = derivation: ''
|
||||
(import "${derivation}")
|
||||
'';
|
||||
}
|
||||
Reference in New Issue
Block a user