I'm confused about what's happening from May 8th on. Is this what you're working with in terms of fixed plans?
May 4: Arr Nice for up to 4 nights. Other bases possible for some or all 4 nights.
May 8: Meet up with friend in Avignon and stay for up to 3 nights. Other bases possible for some or all 3 nights.
Want to see Viviers and Lyon.
May 11: Sleep in Paris.
May 12: Depart for home from CDG.
You have only 8 nights (7 full days) and have mentioned 5 different cities/towns, three of them quite large and full of sightseeing opportunities (Nice, Lyon, Paris). You are at risk of spending a very large part of your precious time traveling between hotels and train/bus stations and sitting on trains/buses rather than actually seeing sights. Can we assume you have visited Paris before and just plan to go there for your flight home on this trip without any sightseeing so you're OK with rolling into Paris late in the afternoon on May 11?
Nice has a lot of museums, a fun market, nice sea views and other sights. It's well-positioned for side trips along the Riviera and up the nearby hilltowns. Honestly, I don't see the point of going there if you aren't going to take some of those side-trips as well as see things in Nice itself. That would mean a minimum of four nights (I'd want more); your arrival day may not be very productive if you're arriving after an overnight flight.
Avignon has a nice historic center as well as some worthwhile sights. It's well-positioned for side trips to a lot of Provencal destinations, but you'd need multiple nights to take advantage of those opportunities.
Lyon is a sight-rich city where I'd want a minimum of three nights in order to have two full days; I spent five nights there without leaving the city. Three nights is all the nights you have between Avignon and Paris.
Viviers looks interesting but doesn't have rail service. According to Rome2Rio.com, you can take a train to Montelimar and then an E19 or E20 bus to Viviers. E19 schedule. E20 schedule (more frequent). Those buses don't run often and could really limit your ability to visit the town without wasting a lot of time.
Please clarify your priorities and timing.