Suhaib Mohammed, 19, was wounded at the house in Milton Keynes but died later.
Mohamed Noor, 33, of Radworthy; and Albert Prempeh, 35, of Langland Road; were found guilty at Luton Crown Court.
The judge said Noor, who fired the revolver, and Prempeh, who had led him to the house last September, should serve a minimum of 30 years.
The victim was shot in the chest at the house in Osprey Close, Eagleston and died in hospital.
The court was told the two had gone to the address to exact revenge on a man known as Hypes, who had robbed Noor earlier and was believed to have been involved in a £4,000 bookmaker robbery the previous day.
Justin Rouse QC, prosecuting, said Noor reached through the window with the gun and pulled the trigger two or three times, but it did not discharge.
“He continued pulling the trigger and the gun fired. Suhaib Mohammed was hit in the chest and died from that injury.”
He said Albert Prempeh had gone with Noor to encourage and assist him and act as look out.
Somali-born Noor, who had admitted manslaughter, told the jury the gun went off accidentally and that his “intention was to rob the £4,000”.
The court heard last year that Noor had been robbed, losing in total £2,000. One of the men involved was Hypes.
Prempeh, who is of Ghanian heritage, said he had been forced at gunpoint by Noor to go to the house, an accusation Noor denied.
After the jury found both men guilty of murder, Judge Richard Foster said: “You were both Class A drug dealers who thought you could operate your depraved business outside the reach of the law.”