Everything worked for me (maybe because now it’s a later CP version). Though in order to force SSL I adjusted the rule to the following:
RewriteCond %{HTTPS} !=on
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
REWRITERULE ^(.*)$ http://cyberpanel/$1 [P]