In 1146 , the Almohad ruler Abd al-Mu ` min turned Rabat 's ribat into a full scale fortress . It was used as a starting point for attacks on Spain .
In 1146 , the Almohad ruler Abd al-Mu ` min turned Rabat 's ribat into a full scale fortress to use as a launching point for attacks on Spain .