跳至內容

I can't add a new env var in the user interface in Environment properties of EB

0

Hi, this must be a bug, but for some reason, I can't add a variable. After I add it, I click Apply, or Continue, and then Apply updates - at this moment I see new variable, but after updating EB is finished, I see in the configuration, the list is the same, the variable is not added. This is a real pain in the a*s, what to do? I can't even report a bug because their support is only about billing for this level. Thank you all.

已提問 3 個月前檢視次數 45 次
2 個答案
0
已接受的答案

This issue is likely related to the environment variable size limit in Elastic Beanstalk rather than a bug. Elastic Beanstalk has a limit of 4096 bytes for all environment variables combined (including their names and values).

When you add a new environment variable and it appears to save initially but then disappears after the update completes, it's typically because you've hit this size limitation. The system allows you to add the variable in the UI, but when it tries to persist the change, it fails silently because the total size exceeds the limit.

To resolve this issue, you could try:

  1. Reduce the size of your existing environment variable names and values where possible
  2. Move some less sensitive configuration directly into your codebase
  3. Remove some existing environment variables that may not be critical
  4. Use AWS Systems Manager Parameter Store to store larger sets of configuration data, and retrieve these in your application code as needed

Another approach is to use the command line with eb setenv VAR1=value1 VAR2=value2 which might provide more explicit error messages about what's causing the problem.
Sources
Environment variables in beanstalk are removed | AWS re:Post
Environment variables and other software settings - AWS Elastic Beanstalk

已回答 3 個月前
  • Even if it's true, it's still a bug. First of all, 4096 is not much, and what's the reason for such a restriction? Secondly, your UI must at least return some message or error information else someone can just be crazy (like me) because there is no obvious reason for it.

0

Yes it worked. But please tell your devs to provide any feedback not to wasy everyone's time.

已回答 3 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。