That follows from the continuous functional calculus of self adjoint operator. Which states that there is an isometric homomorphism
$$\Phi: C(\sigma(\mathcal L)) \to B(\mathcal H)$$
from the space of continuous functions on $\sigma(\mathcal L)$ to $B(H)$, given by $\Phi(f) = f(\mathcal L)$ which extends the map $p(x) \mapsto p(\mathcal L)$ on polynomails. Now if $\lambda \
otin \sigma(\mathcal L)$, then $f(x) = \frac{1}{x-\lambda}$ is continuous on $\sigma(\mathcal L)$. As
$$I= \Phi (1) = \Phi \bigg((x-\lambda) \frac{1}{x-\lambda} \bigg) = (\mathcal L-\lambda I) f(\mathcal L), $$ We see that $f(\mathcal L) = (\mathcal L - \lambda I)^{-1}$ and thus
$$||(\mathcal L - \lambda I)^{-1} || = ||f||_0 = \sup_j \frac{1}{|\lambda - \lambda_j|}$$
So actually we have equality.