To be in with

To be close or near; as, to keep a ship in with the land.
To be on terms of friendship, familiarity, or intimacy with; to secure and retain the favor of.

See also: In, In

Webster's Revised Unabridged Dictionary, published 1913 by G. & C. Merriam Co.