Across Massachusetts, an unusual partnership is bringing renewable energy and traditional farming together on the same land.