Online companies, cooperatives and organizations connecting local farmers and buyers have cropped up in recent years. Now these so-called food hubs are facilitating relationships between farmers and schools.

California-based Ag Link allows school districts to communicate with nearby farmers and buy their produce with the click of a mouse. It's helping schools meet new federal rules requiring more fruits and vegetables in school cafeterias to help prevent childhood obesity.

The new rules require among other things that school provide students at least a half cup of either a fruit or vegetable during lunch and at least a half cup of fruit during breakfast.

The goal of food hubs is to save school districts money and time, by cutting down on transportation costs and by providing an e-commerce platform.