1
0
mirror of https://github.com/firstBitMarksistskaya/jenkins-lib.git synced 2025-08-25 20:09:25 +02:00

Добавил степ createInfobase.groovy, убрал дублирование установки зависимостей, вынес создание базы из последующих степов.

This commit is contained in:
Egor Ivanov
2024-08-24 22:32:56 +03:00
parent 632fc87eb8
commit eefbb89449
5 changed files with 11 additions and 9 deletions

View File

@@ -11,7 +11,6 @@ plugins {
repositories {
mavenCentral()
maven(url = "https://repo.jenkins-ci.org/releases/")
}
tasks {

View File

@@ -26,7 +26,6 @@ class InitFromFiles implements Serializable {
return
}
steps.installLocalDependencies();
Logger.println("Распаковка файлов")
@@ -42,9 +41,6 @@ class InitFromFiles implements Serializable {
srcDir = config.srcDir;
}
def createInfobase = new CreateInfobase(config)
createInfobase.run()
Logger.println("Выполнение загрузки конфигурации из файлов")
String vrunnerPath = VRunner.getVRunnerPath();
def command = "$vrunnerPath update-dev --src $srcDir --ibconnection \"/F./build/ib\""

View File

@@ -32,7 +32,6 @@ class InitFromStorage implements Serializable {
return
}
steps.installLocalDependencies()
String storageVersion = VersionParser.storage()
String storageVersionParameter = storageVersion == "" ? "" : "--storage-ver $storageVersion"
@@ -44,9 +43,6 @@ class InitFromStorage implements Serializable {
String storageCredentials = secrets.storage == UNKNOWN_ID ? repoSlug + "_STORAGE_USER" : secrets.storage
String storagePath = secrets.storagePath == UNKNOWN_ID ? repoSlug + "_STORAGE_PATH" : secrets.storagePath
def createInfobase = new CreateInfobase(config)
createInfobase.run()
steps.withCredentials([
steps.usernamePassword(
storageCredentials,

View File

@@ -0,0 +1,10 @@
import ru.pulsar.jenkins.library.configuration.JobConfiguration
import ru.pulsar.jenkins.library.ioc.ContextRegistry
import ru.pulsar.jenkins.library.steps.CreateInfobase
def call(JobConfiguration config) {
ContextRegistry.registerDefaultContext(this)
def createInfobase = new CreateInfobase(config)
createInfobase.run()
}

View File

@@ -94,6 +94,7 @@ void call() {
createDir('build/out/')
script {
createInfobase config
if (config.infoBaseFromFiles()) {
// Создание базы загрузкой из файлов
initFromFiles config