Web-based labs are key tools for distance education that help to illustrate scientific phenomena, which require costly or difficult-to-assemble equipment. Easy Java Simulations (EJS) is an authoring tool that speeds up the creation of these kind of labs. An excellent proof of the EJS potential is the open source physics (OSP) repository, which hosts hundreds of free EJS labs. Learning management systems, such as Moodle, provide social contexts where students interact with each other. The work described in this paper looks for the synergy of both tools, EJS and Moodle, by supporting the deployment of EJS labs into Moodle and thus enriching them with social features (e.g., chat, forums, and video-conference). To test this approach, the authors have created the ball and beam lab, which helps students of automatic control engineering to train different advanced techniques (robust, fuzzy, and reset control), and compare their performance in relation to a conventional proportional-integral-derivative control.