It’s a pointless, anodyne and unobjectionable pledge that prescribes nothing.
It’s stupid, but not remotely comparable to DEI statements, or commitment to much more specific political ideals.
I am not religious so why should I pledge an oath to be ruled under a god.
I am forced to recite a daily mantra filled with propaganda for a republic which is more concerned about arguing for liberty and justice than it is actually providing liberty and justice.
Right now in the US, there are parallel "flag-waving" and "flag-burning" revolutions. There's no question that the flag-burners are winning the biggest shifts in established power, but the flag-wavers are predominantly the rank-and-file enforcers of the flag-burner policies.
I didn't have to take an oath to get my diploma, but I'm not a medical doctor. I've also never had to swear to tell the truth, the whole truth, etc., as I've never witnessed anything the Courts cared to interrogate me on.
There's a lot of contexts where oaths are required; they're not limited to the USSR and GDR. Oaths are just one of those tools societies use to bind together a heterogeneous people.