pipeline { agent any environment { deployPath = "/var/www/vhosts/bizgaze.com/qa.Bizgaze.com" } stages { stage('Restore packages') { steps { dir('tenants') { git url: 'https://code.bizgaze.com/Matvey/tenants.git' } dir('analytics') { git url: 'https://code.bizgaze.com/Matvey/analytics.git' } dir('apps') { git url: 'https://code.bizgaze.com/Matvey/apps.git' } dir('automation') { git url: 'https://code.bizgaze.com/Matvey/automation.git' } dir('common') { git url: 'https://code.bizgaze.com/Matvey/common.git' } dir('Core') { git url: 'https://code.bizgaze.com/Matvey/core.git' } dir('datasources') { git url: 'https://code.bizgaze.com/Matvey/datasources.git' } dir('desktop') { git url: 'https://code.bizgaze.com/Matvey/desktop.git' } dir('dlls_unibase') { git url: 'https://code.bizgaze.com/Matvey/dlls_unibase.git' } dir('gps') { git url: 'https://code.bizgaze.com/Matvey/gps.git' } dir('helpers') { git url: 'https://code.bizgaze.com/Matvey/helpers.git' } dir('integrations') { git url: 'https://code.bizgaze.com/Matvey/integrations.git' } dir('mongodbprovider') { git url: 'https://code.bizgaze.com/Matvey/mongodbprovider.git' } dir('mssqldbprovider') { git url: 'https://code.bizgaze.com/Matvey/mssqldbprovider.git' } dir('pgsqldbprovider') { git url: 'https://code.bizgaze.com/Matvey/pgsqldbprovider.git' } dir('Platform') { git url: 'https://code.bizgaze.com/Matvey/platform.git' } dir('platform.server') { git url: 'https://code.bizgaze.com/Matvey/platform.server.git' } dir('templates') { git url: 'https://code.bizgaze.com/Matvey/templates.git' } dir('themes') { git url: 'https://code.bizgaze.com/Matvey/themes.git' } dir('unibase.reference') { git url: 'https://code.bizgaze.com/Matvey/unibase.reference.git' } dir('uniconnect') { git url: 'https://code.bizgaze.com/Matvey/uniconnect.git' } dir('utilities') { git url: 'https://code.bizgaze.com/Matvey/utilities.git' } dir('web') { git url: 'https://code.bizgaze.com/Matvey/web.git' } git url: 'https://code.bizgaze.com/unibase/Solution.git' sh 'dotnet restore ${WORKSPACE}/Unibase.Publish.sln' } } stage('Clean') { steps { sh 'dotnet clean ${WORKSPACE}/Unibase.Publish.sln --configuration Release' } } stage('Build') { steps { sh 'dotnet build ${WORKSPACE}/Unibase.Publish.sln --configuration Release --no-restore' } }/* stage('Test') { steps { sh 'dotnet test ${WORKSPACE}/Unibase.Publish.sln --no-restore' } }*/ stage('Publish') { steps { sh 'dotnet publish ${WORKSPACE}/Unibase.Publish.sln -o out --configuration Release --no-restore' } } stage ('Deploy') { steps { sh 'sudo ~/scripts/qa_deploy ${WORKSPACE}/out' } } } post{ success{ emailext body: "${currentBuild.currentResult}: Job ${env.JOB_NAME} build ${env.BUILD_NUMBER}\n More info at: ${env.BUILD_URL}", recipientProviders: [[$class: 'DevelopersRecipientProvider'], [$class: 'RequesterRecipientProvider']], subject: "Jenkins Build ${currentBuild.currentResult}: Job ${env.JOB_NAME}" } always { deleteDir() } cleanup { cleanWs() } } }