Add option for thickjail creation if supported
This commit is contained in:
@@ -3,6 +3,7 @@
|
|||||||
======================
|
======================
|
||||||
Version Description
|
Version Description
|
||||||
|
|
||||||
|
1.0.8......Add option for thickjail creation if supported.
|
||||||
1.0.7......Added 12.1-RELEASE.
|
1.0.7......Added 12.1-RELEASE.
|
||||||
1.0.6......Reload page after base release download.
|
1.0.6......Reload page after base release download.
|
||||||
1.0.5......Add missing uninstall code.
|
1.0.5......Add missing uninstall code.
|
||||||
|
|||||||
@@ -53,6 +53,7 @@ $backup_path = exec("/bin/cat {$configfile} | /usr/bin/grep 'BACKUP_DIR=' | /usr
|
|||||||
$bastille_config = "{$rootfolder}/conf/bastille_config";
|
$bastille_config = "{$rootfolder}/conf/bastille_config";
|
||||||
$jail_dir = "{$rootfolder}/jails";
|
$jail_dir = "{$rootfolder}/jails";
|
||||||
$image_dir = "ext/bastille/images";
|
$image_dir = "ext/bastille/images";
|
||||||
|
$thick_jail = exec("/usr/local/bin/bastille create | grep -wo '\[option\]'");
|
||||||
|
|
||||||
// Ensure the root directory is configured.
|
// Ensure the root directory is configured.
|
||||||
if ($rootfolder == "")
|
if ($rootfolder == "")
|
||||||
|
|||||||
@@ -89,10 +89,16 @@ if($_POST):
|
|||||||
$interface = $pconfig['interface'];
|
$interface = $pconfig['interface'];
|
||||||
endif;
|
endif;
|
||||||
|
|
||||||
if ($_POST['nowstart']):
|
if($_POST['thickjail']):
|
||||||
$cmd = ("/usr/local/bin/bastille create {$jname} {$release} {$ipaddr} {$interface} && /usr/local/bin/bastille start {$jname}");
|
$thick_jail = "-T";
|
||||||
else:
|
else:
|
||||||
$cmd = ("/usr/local/bin/bastille create {$jname} {$release} {$ipaddr} {$interface}");
|
$thick_jail = "";
|
||||||
|
endif;
|
||||||
|
|
||||||
|
if ($_POST['nowstart']):
|
||||||
|
$cmd = ("/usr/local/bin/bastille create {$thick_jail} {$jname} {$release} {$ipaddr} {$interface} && /usr/local/bin/bastille start {$jname}");
|
||||||
|
else:
|
||||||
|
$cmd = ("/usr/local/bin/bastille create {$thick_jail} {$jname} {$release} {$ipaddr} {$interface}");
|
||||||
endif;
|
endif;
|
||||||
|
|
||||||
if ($_POST['Create']):
|
if ($_POST['Create']):
|
||||||
@@ -169,6 +175,9 @@ $document->render();
|
|||||||
$b_action = $l_release;
|
$b_action = $l_release;
|
||||||
html_combobox2('interface',gettext('Network interface'),$pconfig['interface'],$a_action,'',true,false,'action_change()');
|
html_combobox2('interface',gettext('Network interface'),$pconfig['interface'],$a_action,'',true,false,'action_change()');
|
||||||
html_combobox2('release',gettext('Base release'),$pconfig['release'],$b_action,'',true,false,'action_change()');
|
html_combobox2('release',gettext('Base release'),$pconfig['release'],$b_action,'',true,false,'action_change()');
|
||||||
|
if($thick_jail):
|
||||||
|
html_checkbox2('thickjail',gettext('Create a thick container'),!empty($pconfig['thickjail']) ? true : false,gettext('These containers consume more space, but are self contained.'),'',false);
|
||||||
|
endif;
|
||||||
html_checkbox2('nowstart',gettext('Start after creation'),!empty($pconfig['nowstart']) ? true : false,gettext('Start the container after creation.'),'',false);
|
html_checkbox2('nowstart',gettext('Start after creation'),!empty($pconfig['nowstart']) ? true : false,gettext('Start the container after creation.'),'',false);
|
||||||
html_checkbox2('autostart',gettext('Auto start on boot'),!empty($pconfig['autostart']) ? true : false,gettext('Automatically start the container at boot time.'),'',false);
|
html_checkbox2('autostart',gettext('Auto start on boot'),!empty($pconfig['autostart']) ? true : false,gettext('Automatically start the container at boot time.'),'',false);
|
||||||
?>
|
?>
|
||||||
|
|||||||
Reference in New Issue
Block a user