Skip to content

Commit

Permalink
docs: support job parameter
Browse files Browse the repository at this point in the history
- Update Docker image version from `1.3.4` to `1.4.0`
- Add example for triggering Jenkins job with parameters in README
- Add `parameter` input variable description in action.yml

Signed-off-by: appleboy <appleboy.tw@gmail.com>
  • Loading branch information
appleboy committed Oct 5, 2024
1 parent a7c2e0b commit 59bb59e
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ghcr.io/appleboy/drone-jenkins:1.3.4
FROM ghcr.io/appleboy/drone-jenkins:1.4.0

COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
Expand Down
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,24 @@ Trigger multiple jenkins job:
job: "job_1,job_2"
```
Trigger jenkins job with parameter:
```yaml
- name: trigger Job with parameter
uses: appleboy/jenkins-action@master
with:
url: "http://example.com"
user: "example"
token: ${{ secrets.TOKEN }}
job: "job_1"
parameter: "param1=value1,param2=value2"
```
## Input variables
* url - Required. jenkins base url.
* user - Required. jenkins user.
* job - Required. jenkins job name.
* token - Required. jenkins api token.
* insecure - Optional. Allow insecure server connections when using SSL. Default is `false`.
* parameter - Optional. jenkins job parameter, example: `param1=value1,param2=value2`.
2 changes: 2 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ inputs:
insecure:
description: "insecure skip verify"
default: "false"
parameter:
description: "jenkins job parameters"
runs:
using: "docker"
image: "Dockerfile"
Expand Down

0 comments on commit 59bb59e

Please # to comment.