Commit 2b0d60dc authored by jlopez's avatar jlopez
Browse files

Fix #21

parent caa5f8be
......@@ -224,45 +224,10 @@ function generate_container() {
}
}
if(isSingularity) {
PREVIEW += "%post\n";
}
//POST ADMIN
var table = document.getElementById("Table_PostConfig");
for(var i = 1; i < table.rows.length; i++) {
var active = table.rows[i].cells[0].children[0];
if(active.checked) {
var value = table.rows[i].cells[2].children[0].value;
var lines = value.split('\n');
for(var j = 0; j < lines.length; j++) {
var line = lines[j];
if(line != "") {
if(isSingularity) {
PREVIEW += "\t"+ line + "\n";
nrow += 1;
} else {
PREVIEW += "RUN " + line + "\n";
nrow += 1;
}
}
}
PREVIEW += "\n";
nrow += 1;
}
}
var timezone = document.getElementById("timezonePreview").value;
if(isSingularity) {
......@@ -608,8 +573,44 @@ function generate_container() {
}
nrow += 1;
}
}
PREVIEW += "\n\n";
nrow += 2;
//POST ADMIN
var table = document.getElementById("Table_PostConfig");
if(table.rows.length > 0) {
PREVIEW += "\n\n############### Local Post configs ##############\n";
}
for(var i = 1; i < table.rows.length; i++) {
var rows = table.rows[i];
var active = rows.cells[0].children[0];
if(active.checked) {
var value = rows.cells[2].children[0].value;
var lines = value.split('\n');
for(var j = 0; j < lines.length; j++) {
var line = lines[j];
if(line != "") {
if(isSingularity) {
PREVIEW += "\t"+ line + "\n";
nrow += 1;
} else {
PREVIEW += "RUN " + line + "\n";
nrow += 1;
}
}
}
PREVIEW += "\n";
nrow += 1;
}
}
PREVIEW += "\n\n\n";
......
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