When developing functions using the Golang runtime in veFaaS, you need to follow the veFaaS Golang runtime specifications of Volcano Engine.
This topic introduces the runtime environment, development methods, log collection, and compilation and packaging methods for Golang runtime functions (hereinafter referred to as "Golang functions").
Considerations
veFaaS does not currently support online editing of Golang function code through the console. You need to develop your Golang function locally, compile it into a Linux-executable binary file named main, and upload the code to the veFaaS console as a Zip package. veFaaS uses this binary main file to start the user program.
Runtime environment
The runtime environment for Golang functions in veFaaS is based on the debian:bullseye distribution.
Filesystem restrictions
Write operations are only permitted in the /tmp directory within the container. The default temporary storage capacity is 512 MiB. If the capacity limit is exceeded, the service will be evicted and restarted.
tip
Local user data written to disk is not persistent. Data will be deleted when the container is destroyed. Proceed with caution. For persistent storage, see Selecting storage for functions.