The only way out of this is to have a society that lets people who are effectively useless due to automation have food and shelter and healthcare and transportation and entertainment and it all has to be at least pretty nice. No you can't just shove them all into ghettos like we do with Palestine.
The problem is that doesn't feel fair or right. Why does your ass have to get up at 6:00 in the morning and drag your ass into work. It's especially bad because the people who are going to get to stay home and play Xbox get to do that specifically because they are unskilled, stupid and useless.
Maybe a system where everyone gets a share of collective productivity but has to take a turn at work could make those people feel better. So everyone gets their lifetime supply of food/shelter/healthcare/transportation/entertainment in return for their 5-10 years working or whatever the economy actually needs, so there's no shortage of human labor and nobody feels that there's an unfair division of labor either.
Of course the problem with that is another problem contributing to the current situation, there are people who seek maximally unequal shares of wealth for themselves and would fight an egalitarian utopia tooth and nail. Rich and powerful people who can contribute to the 10,000 year old effort of tricking the proles into propping up the aristocracy.