Italy says it has reached a deal with Malta to end the dilemma of a rescue ship stranded for five days with more than 230 migrants on board.

The Lifeline will dock in Malta, but other countries including Italy and France will also receive the migrants.

Italy's interior minister has accused the charity-run ships of operating a "taxi service" for migrants.

Matteo Salvini told the BBC that such ships would never be allowed in Italian ports again.

He added that illegal migrants were risking their lives by making the journey.

A sick passenger was evacuated to Malta from the Lifeline on Monday night.

The German charity Mission Lifeline tweeted that conditions were worsening for the migrants on board its vessel.

French president Emmanuel Macron confirmed that France was one of six countries who would take in "a few dozen individuals", according to AFP.

But he also said the Lifeline had "acted against all rules".

The Maltese authorities plan to investigate the Lifeline captain's actions, suspecting that he had defied an Italian order to let the Libyan coastguard pick up the migrants.

Malta has not given details of the deal, which does not extend to other ships.

Meanwhile, 108 migrants have been taken ashore in Italy from a Danish container ship.

The Alexander Maersk was allowed to dock in the Sicilian port of Pozzallo.

The dispute over the Lifeline echoes that which surrounded the Aquarius, whose 630 migrants were finally taken to the Spanish port of Valencia last week, after being blocked by Italy and Malta.

Italy's new populist government has closed its ports to rescue ships operated by charities in the Mediterranean, saying its EU partners must share the burden of looking after migrants picked up off Libya's coast.

EU leaders face tough negotiations on the migrant crisis at a Brussels summit on Thursday.

More than 600,000 migrants have come ashore in Italy since 2014 - the highest Mediterranean influx.

Charities and human rights campaigners say migrants face serious risks in Libya at the hands of people-smuggling gangs and militias.

They also argue that people fleeing war and persecution have a right to asylum. In recent years refugees from Syria, Iraq and other war zones have headed for the EU.

Italy - the destination for most of the migrants from North Africa - wants EU penalties for countries refusing to accept a quota system.

The Visegrad Group - Poland, Hungary, the Czech Republic and Slovakia - refuse to take in any migrants from other EU states.

Mr Salvini, on a visit to Libya on Monday, called for migrant processing centres to be set up in African countries - an idea also backed by France.

Asylum claims could be assessed before migrants risk their lives in the Mediterranean, but African governments have shown little or no enthusiasm for the idea.