Docker ignore empty paths

This commit is contained in:
Squidly271
2024-02-17 07:13:16 -05:00
committed by GitHub
parent 4ab3760bea
commit e774c8a6a5

View File

@@ -270,6 +270,8 @@ function xmlToCommand($xml, $create_paths=false) {
$Mode = strval($config['Mode']);
if ($confType != "device" && !strlen($containerConfig)) continue;
if ($confType == "path") {
if ( ! trim($hostConfig) || ! trim($containerConfig) )
continue;
$Volumes[] = escapeshellarg($hostConfig).':'.escapeshellarg($containerConfig).':'.escapeshellarg($Mode);
if (!file_exists($hostConfig) && $create_paths) {
@mkdir($hostConfig, 0777, true);