Former Patriots tight end Dwayne Allen has agreed to sign a two-year, $7 million contract with the Miami Dolphins, according to ESPN and other sources.

The deal cannot be made official until Wednesday, when the 2019 free agency period begins.

Allen primarily served as a blocking tight end for New England over the past two seasons.

The 29-year-old caught a career-high 35 passes for 406 yards and 6 touchdowns in his final season with the Indianapolis Colts in 2016, but Allen never came close to duplicating those numbers after the Colts traded him and a 2017 sixth-round draft pick to New England for a 2017 fourth-round pick.

Allen tallied just 13 receptions for 113 yards and one touchdown during his two seasons playing alongside Tom Brady. He was targeted just four times during the 2018 season.

He will join new Dolphins head coach Brian Flores, who was the Patriots defensive play-caller last season.

Another Dolphins roster move involving a player with ties to the Patriots was made on Friday, when they released former New England wide receiver Danny Amendola.