sitespeed.io icon indicating copy to clipboard operation
sitespeed.io copied to clipboard

Removing files after upload to AWS S3, fails on windows

Open Ruprect opened this issue 7 years ago • 4 comments

On Windows, when I select to delete local files after upload to AWS S3, I get an error:

[2019-08-22 13:11:40] INFO: HTML stored in /sitespeed.io/sitespeed-result/www.sitespeed.io/2019-08-22-13-11-21
[2019-08-22 13:11:40] INFO: Uploading /sitespeed.io/sitespeed-result/www.sitespeed.io/2019-08-22-13-11-21 to S3 bucket signatours-sitespeed-io, this can take a while ...
[2019-08-22 13:11:44] INFO: Finished upload to s3
[2019-08-22 13:11:48] ERROR: Could not upload to S3 Error: ENOTEMPTY: directory not empty, rmdir '/sitespeed.io/sitespeed-result/www.sitespeed.io/2019-08-22-13-11-21/logs''

So directory cannot be deleted. If I elect to keep files on local machine, no problem.

This is the command used to run:

docker run --rm -v D:\git\repos\docker\sitespeed.io:/sitespeed.io sitespeedio/sitespeed.io:9.8.1 https://www.sitespeed.io/ --config config/config.json --n 1

And the versions used:

Google Chrome 76.0.3809.87
Mozilla Firefox 68.0
[2019-08-22 13:11:21] INFO: Versions OS: linux 4.9.184-linuxkit nodejs: v10.13.0 sitespeed.io: 9.8.1 browsertime: 5.7.3 coach: 3.6.0

Ruprect avatar Aug 22 '19 13:08 Ruprect

@Ruprect @soulgalore This is an issue with the fs-extra library. below are the issues I found in their repo: https://github.com/jprichardson/node-fs-extra/issues/590 https://github.com/jprichardson/node-fs-extra/issues/532 so we can either wait for them to resolve this issue or we might have to find some other way to do this.

sumeetrohra avatar Sep 06 '19 17:09 sumeetrohra

Ah thanks @sumeetrohra !

@Ruprect if you don't mount any volume (like -v D:\git\repos\dock...) does it work then? Thinking that if you send the files to S3, you may not need them outside of the container, and then there may not be any permission issues deleting it?

soulgalore avatar Sep 06 '19 18:09 soulgalore

I wonder if this works now with the root fix in https://github.com/sitespeedio/sitespeed.io/pull/2710 ?

soulgalore avatar Nov 17 '19 23:11 soulgalore

I think this has been fixed as in https://github.com/sitespeedio/sitespeed.io/issues?page=6&q=is%3Aissue+is%3Aopen#issuecomment-554802351 - please let me know if I should re-open.

soulgalore avatar Apr 13 '21 00:04 soulgalore