The Ranch is starting to replace Danny Masterson for its upcoming third season.

The Netflix comedy has hired Parenthood alum Dax Shepard to be a recurring guest star next season, according to The Hollywood Reporter. Shepard will play Luke Matthews, a former soldier who arrives in Garrison with some history concerning the Iron River Ranch. That's where he meets the Bennetts and sparks an immediate bond with Colt (Ashton Kutcher) and Beau (Sam Elliott), but "Luke's past has a way of catching up with him."

Danny Masterson Fired From The Ranch Amid Sexual Assault Investigation

Shepard's role will have to be limited because he's already booked a pilot this season. He's starring in the Fox comedy, Bless This Mess, which will take first priority in his schedule over filming the Netflix series.

Masterson was fired in December after four women accused him of sexual assault. Production on Season 3 had already begun before Masterson was let go, so the actor will still be part of a few Season 3 episodes before his character Rooster is written out of the story.

The first two seasons of The Ranch are currently streaming on Netflix.