Uploading Theme fails to read zip file

I have been working with ghost for years and I just ran into an issue I have never had before.

When uploading a theme to a live server get the error:

Failed to read zip file

Now, the site has been live for some time, I have worked with this theme for some time. The only thing that has changed for me is that I have always used Linux as a developer and recently moved to windows.

The themes will install fine on the local Ghost running on windows.
Gscan reports no errors.

When uploadings to the live server running ubuntu: “Failed to read zip file”

When using the online version of gscan I get the following error:

Failed to read zip file

myfile.zip

EACCES: permission denied, mkdir

ValidationError: Failed to read zip file at new ValidationError (/opt/gscan/shared/node_modules/ghost-ignition/lib/errors/index.js:134:23) at /opt/gscan/releases/2020-05-01T09:40:40.299Z/lib/index.js:34:19

1 Like

Any updates on this I have been trying to work on this long enough i may end up just moving back to Linux. I remember why I moved away from Windows.

To be clear, this exact same theme will compile and upload find from Linux, but when compiling the the theme from windows, it seems to go fine but will fail to read the zip file on the live server. Same project. Built from windows is not acceptable to live Linux install?

UPDATE: I ended up installing WSL+Ubuntu, and Node, and just run my gulp build and gulp watch command from that mount while I work in windows.

I was getting the same error with gscan.

For me it was a bug with gulp-zip, where gulp-zip would change folder permissions when using Windows, see #112. Issue might be resolved soon with #117.

According to issue #112 there are different ways to fix it. I used gulp-chmod to change permissions. Here’s an example showing how I fixed it.