Preview URLs return a 502 server error
This error occurs when the server running inside the sandbox is binding tolocalhost. As a result, it is only reachable inside the sandbox; the external preview URL will not be able to access it.
To resolve this error, configure your server to bind to IP address 0.0.0.0, so that it listens on all available network interfaces. To avoid IPv4/IPv6 compatibility issues, we recommend using the environment variable HOST instead of setting the address to a static value.
For example, in code:
Deployment fails with STARTUP TCP probe failed or DEADLINE_EXCEEDED error
This error occurs when the server running inside the sandbox is not binding to the correct host and port.
To resolve this error, configure your server to bind to the host and port designated by the HOST and PORT environment variables. Blaxel automatically injects these variables during deployment.
For example:
Models return a 429 error
This error occurs when a model reaches its maximum token limit. To resolve this error, adjust the model’s token usage policy. Token usage policies control the maximum number of tokens your model APIs can handle within a specific time period. You can configure the maximum number of input tokens, output tokens and/or total tokens using these policies.Volume creation fails with an error
This error occurs when a volume is smaller than the template data. To resolve this error, always provision extra space for your volume beyond the template content size. We recommend provisioning at least 20-30% extra space.Hot reloads fail on Webpack previews
This error occurs when a Webpack server is configured to use the same port as local development, but the sandbox preview URL is mapped to a different port. As a result, when hot reloading previews, your client is trying to connect to the local development port instead of the sandbox’s preview URL port. To resolve this error, add a conditional in thewebSocketURL of your webpack/config.dev.js to handle the different ports:
