You've already forked jenkins-lib
mirror of
https://github.com/firstBitMarksistskaya/jenkins-lib.git
synced 2025-08-25 20:09:25 +02:00
Добавление конфигурации для секретов
This commit is contained in:
@@ -1,4 +1,8 @@
|
||||
{
|
||||
"$schema": "schema.json",
|
||||
"sonarScannerToolName": "sonar-scanner"
|
||||
"sonarScannerToolName": "sonar-scanner",
|
||||
"secrets": {
|
||||
"storagePath": "UNKNOWN_ID",
|
||||
"storage": "UNKNOWN_ID"
|
||||
}
|
||||
}
|
@@ -9,6 +9,21 @@
|
||||
"sonarScannerToolName" : {
|
||||
"type" : "string",
|
||||
"description" : "Имя настроенной утилиты sonar-scanner."
|
||||
},
|
||||
"secrets" : {
|
||||
"type" : "object",
|
||||
"id" : "urn:jsonschema:ru:pulsar:jenkins:library:configuration:Secrets",
|
||||
"description" : "Идентификаторы сохраненных секретов",
|
||||
"properties" : {
|
||||
"storagePath" : {
|
||||
"type" : "string",
|
||||
"description" : "Путь к хранилищу конфигурации"
|
||||
},
|
||||
"storage" : {
|
||||
"type" : "string",
|
||||
"description" : "Данные авторизации в хранилище конфигурации"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@@ -13,6 +13,9 @@ class JobConfiguration implements Serializable {
|
||||
@JsonPropertyDescription("Имя настроенной утилиты sonar-scanner.")
|
||||
String sonarScannerToolName
|
||||
|
||||
@JsonPropertyDescription("Идентификаторы сохраненных секретов")
|
||||
Secrets secrets;
|
||||
|
||||
@Override
|
||||
String toString() {
|
||||
return ReflectionToStringBuilder.toString(this, ToStringStyle.JSON_STYLE)
|
||||
|
15
src/ru/pulsar/jenkins/library/configuration/Secrets.groovy
Normal file
15
src/ru/pulsar/jenkins/library/configuration/Secrets.groovy
Normal file
@@ -0,0 +1,15 @@
|
||||
package ru.pulsar.jenkins.library.configuration
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties
|
||||
import com.fasterxml.jackson.annotation.JsonPropertyDescription
|
||||
|
||||
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||
class Secrets implements Serializable {
|
||||
|
||||
@JsonPropertyDescription("Путь к хранилищу конфигурации")
|
||||
String storagePath
|
||||
|
||||
@JsonPropertyDescription("Данные авторизации в хранилище конфигурации")
|
||||
String storage
|
||||
|
||||
}
|
Reference in New Issue
Block a user