diff --git a/Jenkinsfile b/Jenkinsfile index 924e3cc..db15de9 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -14,65 +14,12 @@ build('fistful-server', 'docker-host', finalHook) { checkoutRepo() loadBuildUtils('build-utils') - def pipeDefault - def withWsCache + def pipeErlangService runStage('load pipeline') { env.JENKINS_LIB = "build-utils/jenkins_lib" - pipeDefault = load("${env.JENKINS_LIB}/pipeDefault.groovy") - withWsCache = load("${env.JENKINS_LIB}/withWsCache.groovy") + env.SH_TOOLS = "build-utils/sh" + pipeErlangService = load("${env.JENKINS_LIB}/pipeErlangService.groovy") } - pipeDefault() { - - if (!masterlikeBranch()) { - - runStage('compile') { - withGithubPrivkey { - sh 'make wc_compile' - } - } - - runStage('lint') { - sh 'make wc_lint' - } - - runStage('xref') { - sh 'make wc_xref' - } - - runStage('dialyze') { - withWsCache("_build/default/rebar3_22.3.1_plt") { - sh 'make wc_dialyze' - } - } - - runStage('test') { - sh "make wdeps_test" - } - - } - - runStage('make release') { - withGithubPrivkey { - sh "make wc_release" - } - } - - runStage('build image') { - sh "make build_image" - } - - try { - if (masterlikeBranch()) { - runStage('push image') { - sh "make push_image" - } - } - } finally { - runStage('rm local image') { - sh 'make rm_local_image' - } - } - - } + pipeErlangService.runPipe(true, true) } diff --git a/build-utils b/build-utils index 4e6aae0..91587cc 160000 --- a/build-utils +++ b/build-utils @@ -1 +1 @@ -Subproject commit 4e6aae0f31885d3c56d09c72de7ef8d432149dbf +Subproject commit 91587cccf7f5dbb2b0ccf4ca3b838b22c8c588a0