github.com/jaylevin/jenkins-library@v1.230.4/resources/metadata/githubSetCommitStatus.yaml (about) 1 metadata: 2 name: githubSetCommitStatus 3 description: Set a status of a certain commit. 4 longDescription: | 5 This step allows you to set a status for a certain commit. 6 Details can be found here: https://developer.github.com/v3/repos/statuses/. 7 8 Typically, following information is set: 9 10 * state (pending, failure, success) 11 * context 12 * target URL (link to details) 13 14 It can for example be used to create additional check indicators for a pull request which can be evaluated and also be enforced by GitHub configuration. 15 spec: 16 inputs: 17 secrets: 18 - name: githubTokenCredentialsId 19 description: Jenkins 'Secret text' credentials ID containing token to authenticate to GitHub. 20 type: jenkins 21 params: 22 - name: apiUrl 23 aliases: 24 - name: githubApiUrl 25 description: Set the GitHub API URL. 26 scope: 27 - GENERAL 28 - PARAMETERS 29 - STAGES 30 - STEPS 31 type: string 32 default: https://api.github.com 33 mandatory: true 34 - name: commitId 35 description: The commitId for which the status should be set. 36 resourceRef: 37 - name: commonPipelineEnvironment 38 param: git/commitId 39 scope: 40 - PARAMETERS 41 - STAGES 42 - STEPS 43 type: string 44 mandatory: true 45 - name: context 46 description: Label for the status which will for example show up in a pull request. 47 scope: 48 - PARAMETERS 49 - STAGES 50 - STEPS 51 type: string 52 mandatory: true 53 - name: description 54 description: Short description of the status. 55 scope: 56 - PARAMETERS 57 - STAGES 58 - STEPS 59 type: string 60 - name: owner 61 aliases: 62 - name: githubOrg 63 description: Name of the GitHub organization. 64 resourceRef: 65 - name: commonPipelineEnvironment 66 param: github/owner 67 scope: 68 - PARAMETERS 69 - STAGES 70 - STEPS 71 type: string 72 mandatory: true 73 - name: repository 74 aliases: 75 - name: githubRepo 76 description: Name of the GitHub repository. 77 resourceRef: 78 - name: commonPipelineEnvironment 79 param: github/repository 80 scope: 81 - PARAMETERS 82 - STAGES 83 - STEPS 84 type: string 85 mandatory: true 86 - name: status 87 description: Status which should be set on the commitId. 88 scope: 89 - PARAMETERS 90 - STAGES 91 - STEPS 92 type: string 93 possibleValues: 94 - failure 95 - pending 96 - success 97 mandatory: true 98 - name: targetUrl 99 description: Target URL to associate the status with. 100 scope: 101 - PARAMETERS 102 - STAGES 103 - STEPS 104 type: string 105 - name: token 106 aliases: 107 - name: githubToken 108 - name: access_token 109 description: GitHub personal access token as per https://help.github.com/en/github/authenticating-to-github/creating-a-personal-access-token-for-the-command-line. 110 scope: 111 - GENERAL 112 - PARAMETERS 113 - STAGES 114 - STEPS 115 type: string 116 mandatory: true 117 secret: true 118 resourceRef: 119 - name: githubTokenCredentialsId 120 type: secret 121 - type: vaultSecret 122 default: github 123 name: githubVaultSecretName