I am interested in the local geometry of holomorphic curves in Calabi-Yau threefolds. The setup and question are then the following:

Consider a $\mathbb{C}^2$ bundle over a compact Riemann surface $\Sigma_g$ of genus $g>1$ endowed with a unitary connection. The first Chern class of the bundle will be $-K$ with $K$ the canonical class of $\Sigma_g$. What are the necessary and sufficient conditions which must be imposed on the unitary connection such that there exists a Ricci-flat metric in a neighborhood of the zero-section which induces the connection on the normal bundle?