Keep compatibility with psych 3.1+ since permitted_classes and aliases were
added as keyword arguments to safe_load.
Note, psych 4 changed the interface to drop support with positional arguments for the
permitted_classes.
Now, we must explicitly specify them using kwargs.
Update safe_load calls to work with psych 3/4
Part of https://github.com/ManageIQ/manageiq/issues/22696