Status: Closed (View Workflow)
We need a command-line linter - the Jenkins CLI is right there, so let's take advantage of it!
- links to
Still debating also adding a shell script that you can download and run without needing to have CLI SSH port access to the master. Haven't decided yet.
Code changed in jenkins
User: Andrew Bayer
[FIXED JENKINS-39923] Add a CLI endpoint for the linter
Can be used like:
ssh -p [sshd port on master] localhost declarative-linter < Jenkinsfile
Tweaks still needed for permissions (right now, it's anyone with read
access, which, I think, is OK) and possibly reading the file reading
than just taking it from stdin.
Hi, I'm having trouble finding the CLI. I'm using docker.
$ cat Dockerfile.pipeline FROM jenkins:2.46.1-alpine RUN /usr/local/bin/install-plugins.sh \ pipeline-model-definition
When I run the image, I can't find declarative-linter anywhere. Am I missing an install step?
Initial PR up at https://github.com/jenkinsci/pipeline-model-definition-plugin/pull/58