mirror of
https://github.com/SAP/jenkins-library.git
synced 2025-03-03 15:02:35 +02:00
change naming of parameter holding the path to the pipeline script.
This commit is contained in:
parent
13139da01e
commit
67630d829b
@ -13,12 +13,12 @@ none
|
||||
| -------------------|-----------|-----------------|-----------------|
|
||||
| `repoUrl` | yes | | |
|
||||
| `branch` | no | 'master' | |
|
||||
| `jenkinsfilePath` | no | 'Jenkinsfile' | |
|
||||
| `path` | no | 'Jenkinsfile' | |
|
||||
| `credentialsId` | no | An empty String | |
|
||||
|
||||
* `repoUrl` The url to the git repository of the pipeline to be loaded.
|
||||
* `branch` The branch of the git repository from which the pipeline should be checked out.
|
||||
* `jenkinsfilePath` The path to the Jenkinsfile, inside the repository, to be loaded.
|
||||
* `path` The path to the Jenkinsfile, inside the repository, to be loaded.
|
||||
* `credentialsId` The Jenkins credentials containing user and password needed to access a private git repository.
|
||||
|
||||
## Return value
|
||||
@ -37,5 +37,5 @@ none
|
||||
## Example
|
||||
|
||||
```groovy
|
||||
centralPipelineLoad repoUrl: "https://github.com/MyOrg/MyPipelineRepo.git", branch: 'feature1', jenkinsfilePath: 'path/to/Jenkinsfile', credentialsId: 'MY_REPO_CREDENTIALS'
|
||||
centralPipelineLoad repoUrl: "https://github.com/MyOrg/MyPipelineRepo.git", branch: 'feature1', path: 'path/to/Jenkinsfile', credentialsId: 'MY_REPO_CREDENTIALS'
|
||||
```
|
||||
|
@ -93,7 +93,7 @@ class CentralPipelineLoadTest extends PiperTestBase {
|
||||
execute() {
|
||||
|
||||
node() {
|
||||
centralPipelineLoad repoUrl: "https://test.com/anotherRepo.git", branch: 'feature', jenkinsfilePath: 'path/to/Jenkinsfile', credentialsId: 'abcd1234'
|
||||
centralPipelineLoad repoUrl: "https://test.com/anotherRepo.git", branch: 'feature', path: 'path/to/Jenkinsfile', credentialsId: 'abcd1234'
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -14,7 +14,7 @@ def call(Map parameters = [:]) {
|
||||
// The coordinates of the central pipeline script
|
||||
def repo = utils.getMandatoryParameter(parameters, 'repoUrl', null)
|
||||
def branch = utils.getMandatoryParameter(parameters, 'branch', 'master')
|
||||
def path = utils.getMandatoryParameter(parameters, 'jenkinsfilePath', 'Jenkinsfile')
|
||||
def path = utils.getMandatoryParameter(parameters, 'path', 'Jenkinsfile')
|
||||
|
||||
// In case access to the repository containing the central pipeline
|
||||
// script is restricted the credentialsId of the credentials used for
|
||||
|
Loading…
x
Reference in New Issue
Block a user