で暮らしていた

lived in

→ で
phrase Rare #41,973
lived in で indicates the place where someone lived or the means they lived on, such as money. いた describes a continuing state in the past.
JA: 彼女は長い間、京都で暮らしていた。
EN: She lived in Kyoto for a long time.

トムとメアリーは一時期ボストンで暮らしていた。

Tom and Mary lived in Boston for a while.

彼はその少ないお金で暮らしていた。

He lived on that small amount of money.