Since mason bees don't make their own holes you can encourage them to nest close to your garden by providing suitable nesting holes for them. Many garden supply companies sell mason bee houses. You can also easily make one, and there are good instructions on how to do that here. You can also purchase mason bees, but you really shouldn't need to. As the saying goes, if you build it (or buy it), they will come. I put up my mason bee houses a little over a week ago, and the bees were using them immediately. (Actually they were using them before the houses were put up since I had them sitting on the porch!) You should put your bee house someplace with a bit of protection from rain and other nasty weather (if it doesn't have it's own roof built in), and if it can get morning sun, that's really optimal. You really don't need to worry about having the bees close to where you are. Unlike honey bees, mason bees aren't aggressive at all since they have no honey stores to protect. They can sting, but you pretty much have to squish one to get it to do so. As I was taking the pictures for this post the bees were actually hitting me since I was in their flight path to their nests, and I didn't get stung once. And they really are fascinating to watch as they go about their bee business.
So, if you're planning to grow anything that requires a bit of bee action, I'd really suggest making friends with some of our own orchard bees. They're some of the best friends a gardener can have!