Edit the following file (be sure to replace username.tld with the appropriate username):
nano /opt/cpanel/ea-php70/root/etc/php-fpm.d/username.domain.conf
This assumes we are enabling these functions for PHP version 7.0. Simply change according to which PHP version you'd like by replace ea-php70 with ea-php56 for 5.6 etc.
Simply remove exec and shell_exec from the following line: php_admin_value[disable_functions]