We present a new connection between the Hele-Shaw flow, also known as two-dimensional Laplacian growth, and the theory of holomorphic discs with boundary contained in a totally real submanifold. Using this, we prove short-time existence and uniqueness of the Hele-Shaw flow with varying permeability both when starting from a single point and also when starting from a smooth Jordan domain. Applying the same ideas, we prove that the moduli space of smooth quadrature domains is a smooth manifold whose dimension we also calculate, and we give a local existence theorem for the inverse potential problem in the plane.