Skip to content
Back

Permission denied error Appwrite CLI on "init project"

  • 0
  • Self Hosted
  • Functions
Rockafella
19 Apr, 2025, 13:56

Hey all, I was working on deploying functions, but halfway something didn't work. So I decided to start again. But now, whenever I use "init project" I get a permission denied error, it seems because the appwrite json file is locked. The stacktrace is as follows (removed identifiers): appwrite init project --verbose ? How would you like to start? Link directory to an existing project ? Choose your organization zzzzzzzzzzzzzzzzzzzz ? Choose your Appwrite project. zzzzzzzzzzzzzzzzzzz Error: EACCES: permission denied, open '/appwrite/appwrite.json' at Object.openSync (node:fs:599:3) at Object.openSync (pkg/prelude/bootstrap.js:793:32) at Object.writeFileSync (node:fs:2221:35) at Local.write (/snapshot/sdk-for-cli/lib/config.js:85:12) at Local.set (/snapshot/sdk-for-cli/lib/config.js:94:14) at Local.setProject (/snapshot/sdk-for-cli/lib/config.js:419:14) at initProject (/snapshot/sdk-for-cli/lib/commands/init.js:104:21) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) { errno: -13, syscall: 'open', code: 'EACCES', path: '/appwrite/appwrite.json' }

Any ideas on how to solve this?

(btw, I can open the project via the Console just fine)

TL;DR
Developers encountering a 'Permission Denied' error when using "init project" with Appwrite CLI. This issue likely occurs due to a locked appwrite.json file that triggers the EACCES error. The problem may be resolved by ensuring appropriate permissions for the file or directory, particularly write permissions, and checking if the file is not locked by another process. Developers may need to run the command with elevated permissions or change file permissions accordingly.
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more