Pivotal Cloud Foundry® all versions
When pushing your app you receive the following errors.
Error: From App trace
Server error, status code: 500, error code: 10011, message: Database error
Please check your Cloud Controller logs for the following message.
"message":"Mysql2::Error: Data too long for column 'encrypted_environment_variables' at row 1: INSERT INTO `apps`
There is a 65,535 character limit for environment variables (post-encryption) for apps. The Linux kernel itself has limits on the size of a start command which is how we feed environment variables into the process. Setting this limit allows us to ensure the process will start.
In order to fix this issue, you need to reduce the size of your environment variables. You may find that there are some images encoded into your environment variables that are causing you to hit this limit. If so remove these images from your environment variables and push your app again.
Question: The inevitable question is can pivotal increase the size?
Answer: Unfortunately, this is not something we will end up doing. The Linux kernel itself has limits on the size of a start command which is how we feed environment variables into the process, therefore, having this limit allows us to ensure the process will actually start.