Set whether a package may run in the background:
cmd appops set <package_name> RUN_IN_BACKGROUND ignore|allow
ignore freezes background work. allow restores it.
ignore
allow