mirror of https://github.com/apache/cloudstack.git
Summary: Fix S3 from trying to upload directories found in template dirs
Detail: The S3 upload code fails on directories in the templates dir, such as "KVMHA" that gets created for KVM. This skips directories in the templates dir. BUG-ID: CLOUDSTACK-1056 Bugfix-for: 4.1 (master) Signed-off-by: Marcus Sorensen <marcus@betterservers.com> 1359390176 -0700
This commit is contained in:
parent
afd7de7e33
commit
fe9398dc73
|
|
@ -398,7 +398,8 @@ public class NfsSecondaryStorageResource extends ServerResourceBase implements
|
|||
@Override
|
||||
public boolean accept(final File directory,
|
||||
final String fileName) {
|
||||
return !fileName.startsWith(".");
|
||||
File fileToUpload = new File(directory.getAbsolutePath() + "/" + fileName);
|
||||
return !fileName.startsWith(".") && !fileToUpload.isDirectory();
|
||||
}
|
||||
}, new ObjectNamingStrategy() {
|
||||
@Override
|
||||
|
|
|
|||
Loading…
Reference in New Issue