How to find the Magento 2 frontend base URL using the command line?

Since Magento 2.2, you can use a new console command bin/magento config:show for it:

bin/magento config:show web/secure/base_url
bin/magento config:show web/unsecure/base_url]