Yes, they are both ok, "to" probably being more common. The second set of your sentences doesn't mean anything to me but perhaps you meant I get high only with people I know. (in which case only "with" is appropriate)
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.