If you know Ubuntu, you might ask to yourself why this post even exists. PHP 7.2 is included in the official Ubuntu 18.04 (bionic) repository? Why even bother to make a post about it?
And you’re right - PHP 7.2 is included in the default Ubuntu bionic repository. But some of the PHP packages you might require are not included in the default category.
Packages such as php7.2-zip and php7.2-mbstring are included in the universe category (also referred as distribution component by apt), not in the main category.
And when installing Ubuntu 18.04 Server, the universe category is not enabled by default.
Therefore, to be able to install all php7.2 packages, you need to enable the universe category.
You can now install all available php7.2 packages.
It’s as easy as that.