Commit 8cdae3b9 authored by remy's avatar remy
Browse files

adding an execline box

parent 1ec4abf5
......@@ -113,6 +113,8 @@ function generate_container() {
var pythonversion = document.getElementById("selectedPython").value;
var execline = document.getElementById("ExecLineInput").value;
var nrow = 2;
//HEADER
......@@ -470,19 +472,33 @@ function generate_container() {
nrow += 3;
//END
if(isSingularity) {
PREVIEW += "%apprun run\n";
PREVIEW += "\texec /bin/bash \"$@\"\n";
PREVIEW += "\n";
PREVIEW += "%runscript\n";
PREVIEW += "\texec /bin/bash \"$@\"\n";
PREVIEW += "\n";
nrow += 6;
} else {
PREVIEW += "CMD exec /bin/bash \"$@\"\n";
PREVIEW += "\n";
nrow += 2;
if(execline != "") {
if(isSingularity) {
PREVIEW += "%runscript\n";
PREVIEW += "\t"+execline+"\n";
PREVIEW += "\n";
nrow += 6;
} else {
PREVIEW += "CMD"+execline+"\n";
PREVIEW += "\n";
nrow += 2;
}
}
else {
if(isSingularity) {
PREVIEW += "%apprun run\n";
PREVIEW += "\texec /bin/bash \"$@\"\n";
PREVIEW += "\n";
PREVIEW += "%runscript\n";
PREVIEW += "\texec /bin/bash \"$@\"\n";
PREVIEW += "\n";
nrow += 6;
} else {
PREVIEW += "CMD exec /bin/bash \"$@\"\n";
PREVIEW += "\n";
nrow += 2;
}
}
......
......@@ -216,6 +216,24 @@ foreach ($db->getAllActiveSectionParent() as $s){
</div>
</div>
</div>
<br/>
<div class="col-12">
<div class="card border border-dark">
<div class="card-header bg-dark text-light">
Exec line (%Runscript / CMD) :
</div>
<div class="card-body">
<div class="form-group">
<label for="ExecLineInput" class="font-weight-bold">Exec Line :</label>
<input type="text" class="form-control" id="ExecLineInput" value='exec /bin/bash "$@"'>
</div>
</div>
</div>
</div>
</div>
<div class="col-8">
......
Supports Markdown
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