How can I use --secret option to build the image with Go SDK

Is Go SDK client not using BuildKit as the backend? I can’t find a setting in the ImageBuildOptions struct.

I have never used Go SDK client, so I may say some nonsense, but do you mean this client?

Here is the ImageBuildOptions struct:

I don’t know if it uses buildkit or not, but you can find out by building an image with some longrunning commands and if you can see containers created n the meantime, that’s not buildkit.