Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Bug Report: Invalid specification param: Specification must be one of: #158

Open
2 tasks done
hej2010 opened this issue Feb 7, 2025 · 3 comments
Open
2 tasks done
Labels
bug Something isn't working

Comments

@hej2010
Copy link

hej2010 commented Feb 7, 2025

👟 Reproduction steps

When running appwrite push functions --all the CLI gives the error Invalid 'specification' param: Specification must be one of:

👍 Expected behavior

The push works.

👎 Actual Behavior

Gives an error for every function.

The appwrite.json file contains a line "specification": "s-1vcpu-512mb" for every function. After removing that line the push command works but the line gets added back when pulling the functions (appwrite pull functions).

🎲 Appwrite version

Version 1.6.x

💻 Operating system

Linux

🧱 Your Environment

Self-hosted 1.6.1 with Docker.
CLI 6.2.0

👀 Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

@hej2010 hej2010 added the bug Something isn't working label Feb 7, 2025
@stnguyen90 stnguyen90 marked this as a duplicate of appwrite/appwrite#9482 Mar 11, 2025
@stnguyen90
Copy link
Contributor

stnguyen90 commented Mar 14, 2025

@hej2010 thanks for raising this issue! 🙏🏼

Looks like this can happen to orgs on the Free plan if they don't have s-0.5vcpu-512mb for specification.

For self-hosted, you may need to tweak your APP_FUNCTION_CPUS_DEFAULT and APP_FUNCTION_MEMORY_DEFAULT to 8 and 8192 respectively.

@hej2010
Copy link
Author

hej2010 commented Mar 15, 2025

Thanks, changing .env to

_APP_FUNCTIONS_CPUS=8
_APP_FUNCTIONS_MEMORY=8192

solved it :)

@ibaraki-douji
Copy link

The fix also worked for me :)

So apparently you check if the specification fit in the envs before showing it, tho if everything is at 0, no specific specification will work (none will use the default).

To fix this issue, could it be possible to add something in the app to check if both values are 0 then:

  • don't check the specification and allow all of them
  • or check the system CPU/mem and set thoses as the envs value (so the limit is the current server) (i think it's the better)
  • or only allow some of the specification like the default s-1vcpu-512mb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants