A compact electron accelerator of race-track microtron (RTM) type is under construction at the Technical University of Catalonia. The beam is accelerated by a C-band accelerating structure powered by a magnetron. The beam can be extracted from various orbits with energies from 6 MeV to 12 MeV. For the sake of compactness the bending magnets are placed in vacuum and as a source of magnetic field a permanent magnetic material is used. The main envisaged application of the machine is the Intraoperative Radiation Therapy. In the talk the design of the RTM and its main characteristics will be explained and the current status of the project will be discussed