Bugfix: correct path for pem file
Bugfix: use correct local var