The reasons they cannot adequately staff their pharmacies is the all three outlets mentioned are horrible places to work.
The last time I went to a CVS, they had a sign paying Pharmacy tech’s $18/hour. Our local In-n-Out starts some positions at $17/hour and the people who visit In-n-Out generally want to be there, unlike a Pharmacy where many are there because they feel awful or are tending to sick family members.
They wouldn’t have a shortage if they actually used some of that savings from replacing employees with automated cashiers to actually compensate people who are supposed to have at least some training to handle life saving drugs.
If CVS was paying $20/hour to start they probably wouldn’t have a problem finding more people.
Meanwhile, my local CVS — 24 hours, but who knows how much longer — has to close their drive-through, and stop answering their phones. The only way to interact with a person is to stand in a long line and hope what their app tells you is ready is accurate.