pluginpal / strapi-plugin-config-sync

:recycle: CLI & GUI for continuous migration of config data across environments
https://www.pluginpal.io/plugin/config-sync
MIT License
256 stars 36 forks source link

Download config does not work v3.0.3 #156

Closed Pijuli closed 1 week ago

Pijuli commented 1 week ago

Bug report

Describe the bug

Download config does not work. Not working in development locally, not working on production I don't need it, I was just curious. So no problem!

Screenshots

image

System

Node.js version: 20.18.0 YARN version: 1.22.19 Strapi version: 5.3.0 Plugin version: 3.0.3 Database: PostgreSQL Operating system: Ubuntu24.04/Docker

Pijuli commented 1 week ago

I found a self explanatory error on the console that I didn't see before And I couldn't find information on zip requirement in the docs either. Not using any strange docker, node:20-alpine. A bit naked, but....

Up to you what to do with the issue. Cheers!

cms-1 | Error: Command failed: zip -r config-2024-11-11T17:14:44.819Z.zip * cms-1 | /bin/sh: zip: not found cms-1 | cms-1 | at genericNodeError (node:internal/errors:984:15) cms-1 | at wrappedFn (node:internal/errors:538:14) cms-1 | at checkExecSyncError (node:child_process:891:11) cms-1 | at Object.execSync (node:child_process:963:15) cms-1 | at Object.zipConfigFiles (/home/node/node_modules/strapi-plugin-config-sync/server/services/main.js:77:18) cms-1 | at Object.zipConfig (/home/node/node_modules/strapi-plugin-config-sync/server/controllers/config.js:97:57) cms-1 | at dispatch (/home/node/node_modules/koa-compose/index.js:42:32) cms-1 | at returnBodyMiddleware (/home/node/node_modules/@strapi/core/dist/services/server/compose-endpoint.js:45:24) cms-1 | at dispatch (/home/node/node_modules/koa-compose/index.js:42:32) cms-1 | at policiesMiddleware (/home/node/node_modules/@strapi/core/dist/services/server/policy.js:15:11) cms-1 | [2024-11-11 17:14:44.830] http: GET /config-sync/zip (43 ms) 500

boazpoolman commented 1 week ago

Ah that makes sense. The zip cli is not available in your alpine docker image. I will replace this with a node zip library, probably https://www.npmjs.com/package/adm-zip.

The zip functionality is rather new, hope you don't mind being the guinea pig :)

boazpoolman commented 1 week ago

This was fixed and released with v3.0.4.

Thanks @Pijuli for being attentive. If you see any other issues, please feel free to report them. Small or big.

Pijuli commented 1 week ago

I don't mind. Thanks to you! 😊

Pijuli commented 1 week ago

Guinea pig reporting. Everything looks good to me! @boazpoolman thank you!