The transient IGR J01217-7257 in the Small Magellanic Cloud was found to be in a new outburst during INTEGRAL observations. We triggered an XMM-Newton target of opportunity observation near outburst maximum, which lead to the discovery of X-ray pulsations with a period of 2.165 s. This period is very similar to that detected from XTE J0119-731, suggesting that both sources are identical. The pulse profile obtained from the EPIC-pn instrument is complex and highly energy dependent. Pulse-phase spectroscopy reveals variations in the spectral slope correlated with the changes in flux during the pulse, with the harder X-ray spectrum at pulse maximum and softer during minimum. Analysis of XMM-Newton reflection grating spectra reveals the presence of emission lines that suggest the presence of ionized material around the neutron star. By monitoring the system during its outburst with Swift/XRT we detected a possible transition from the accretor to the propeller stage.