How to fix «Failed to initialize global composer: Composer could not find the config file: var/composer_home/composer.json» on `bin/magento setup:upgrade`?

Create the file var/composer_home/composer.json with the {} contents.

magento.stackexchange.com/a/319488