Commit 52c61522 authored by Valentin Reis's avatar Valentin Reis

adds a singularity test.

parent f725b8c2
Pipeline #7305 failed with stages
in 3 minutes and 36 seconds
...@@ -6,6 +6,8 @@ let cn = "testContainer" ...@@ -6,6 +6,8 @@ let cn = "testContainer"
let basicManifest = lib.manifestDir ++ "basic.json" let basicManifest = lib.manifestDir ++ "basic.json"
let singularityManifest = lib.manifestDir ++ "singularity.json"
let argIfTest = let argIfTest =
λ(isTest : Bool) λ(isTest : Bool)
→ { isTest = → { isTest =
...@@ -16,7 +18,24 @@ let argIfTest = ...@@ -16,7 +18,24 @@ let argIfTest =
let Powercap = < Cap : Text | NoCap : {} > let Powercap = < Cap : Text | NoCap : {} >
in { run = in { run-singularity =
lib.makeBase
( lib.emptyMakeBaseArg "echo" singularityManifest cn
⫽ { args =
[ message ]
, verbose =
True
, singularity =
True
, cmdwants =
[] : List Text
, cmdavoids =
[ "Traceback" ]
, timeout =
[ 600 ] : Optional Natural
}
)
, run =
lib.makeBase lib.makeBase
( lib.emptyMakeBaseArg "echo" basicManifest cn ( lib.emptyMakeBaseArg "echo" basicManifest cn
⫽ { args = ⫽ { args =
......
...@@ -67,6 +67,8 @@ let MakeBaseArg = ...@@ -67,6 +67,8 @@ let MakeBaseArg =
List Text List Text
, verbose : , verbose :
Bool Bool
, singularity :
Bool
, cmdwants : , cmdwants :
List Text List Text
, cmdavoids : , cmdavoids :
...@@ -97,6 +99,8 @@ let emptyMakeBaseArg = ...@@ -97,6 +99,8 @@ let emptyMakeBaseArg =
[] : List Text [] : List Text
, verbose = , verbose =
True True
, singularity =
False
, cmdwants = , cmdwants =
[] : List Text [] : List Text
, cmdavoids = , cmdavoids =
...@@ -116,6 +120,10 @@ let emptyMakeBaseArg = ...@@ -116,6 +120,10 @@ let emptyMakeBaseArg =
let addVerbose = λ(v : Bool) → if v then [ "--verbose" ] else [] : List Text let addVerbose = λ(v : Bool) → if v then [ "--verbose" ] else [] : List Text
let addSingularity =
λ(v : Bool)
→ if v then [ "--container-runtime", "singularity" ] else [] : List Text
let addPowercap = let addPowercap =
λ(p : Powercap) λ(p : Powercap)
→ merge → merge
...@@ -142,6 +150,7 @@ let makeBase = ...@@ -142,6 +150,7 @@ let makeBase =
⫽ { args = ⫽ { args =
[ "--nrm_log", "./nrm_log" ] [ "--nrm_log", "./nrm_log" ]
# addVerbose args.verbose # addVerbose args.verbose
# addSingularity args.singularity
# addPowercap args.powercap # addPowercap args.powercap
, vars = , vars =
[ { varname = [ { varname =
...@@ -269,6 +278,8 @@ let appTest = ...@@ -269,6 +278,8 @@ let appTest =
args.args args.args
, verbose = , verbose =
True True
, singularity =
False
, cmdwants = , cmdwants =
[] : List Text [] : List Text
, cmdavoids = , cmdavoids =
......
{
"acKind": "ImageManifest",
"acVersion": "0.6.0",
"name": "test",
"app": {
"isolators": [
{
"name": "argo/scheduler",
"value": {
"policy": "SCHED_OTHER",
"priority": "0"
}
},
{
"name": "argo/container",
"value": {
"cpus": "1",
"mems": "1"
}
},
{
"name": "argo/perfwrapper",
"value": {
"enabled": "0"
}
},
{
"name": "argo/power",
"value": {
"enabled": "1",
"profile": "1",
"policy": "NONE",
"damper": "1e9",
"slowdown": "1.1"
}
},
{
"name": "argo/monitoring",
"value": {
"enabled": "1",
"ratelimit": "10000000"
}
},
{
"name": "argo/hwbind",
"value": {
"enabled": "0"
}
}
]
},
"image": {
"path": "docker://ubuntu",
"type": "docker"
}
}
...@@ -444,6 +444,9 @@ let ...@@ -444,6 +444,9 @@ let
doDhrun dhrunscript; doDhrun dhrunscript;
testGeneric = doDhrunKey genericTestName; testGeneric = doDhrunKey genericTestName;
testSingularity = (doDhrunKey "run-singularity").overrideAttrs (o:{
buildInputs=o.buildInputs++[ pkgs.singularity ];
});
testSTREAM = addBI (doDhrunApp "stream") stream; testSTREAM = addBI (doDhrunApp "stream") stream;
testAMG = addBI (doDhrunApp "amg") amg; testAMG = addBI (doDhrunApp "amg") amg;
......
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