I want to use the Jenkins declarative script linter via the CLI.
I have specified a fixed SSHD port in Jenkins Global Security.
I have shared my SSH public key with my account on the Jenkins server, so I can connect to the server using SSH.
However, when I try to run the linter I get an error:
$ ssh -p <port> hudsonmaster declarative-linter < Jenkinsfile
Permission denied (publickey).
Can anyone help me please?