Use correct private key in invoke task