forked from scriptwithabhi/Mule-Maven-Project
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathazure-pipelines.yml
52 lines (46 loc) · 1.26 KB
/
azure-pipelines.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
trigger:
batch: true
branches:
include:
- dev
paths:
exclude:
- azure-pipelines.yml
- pom.xml
pool:
vmImage: 'ubuntu-latest'
variables:
- group: Build-Variable-Group
- name: MAVEN_CACHE_FOLDER
value: $(Pipeline.Workspace)/.m2/repository
- name: MAVEN_OPTS
value: '-Dmaven.repo.local=$(MAVEN_CACHE_FOLDER)'
steps:
- task: CacheBeta@0
inputs:
key: $(Build.SourcesDirectory)/pom.xml
path: $(MAVEN_CACHE_FOLDER)
displayName: Cache Maven local repo
- task: DownloadSecureFile@1
name: settingsxml
inputs:
secureFile: 'settings.xml'
- task: PowerShell@2
inputs:
targetType: 'inline'
script: |
New-Item -Type Directory -Force "${HOME}/.m2"
Copy-Item -Force "$(settingsxml.secureFilePath)" "${HOME}/.m2/settings.xml"
- task: Maven@3
inputs:
mavenPomFile: 'pom.xml'
mavenOptions: '-Xmx3072m'
jdkVersionOption: '1.8'
jdkArchitectureOption: 'x64'
mavenAuthenticateFeed: true
publishJUnitResults: false
javaHomeOption: 'JDKVersion'
mavenVersionOption: 'Default'
effectivePomSkip: true
sonarQubeRunAnalysis: false
goals: 'clean install package deploy $(MAVEN_OPTS) -DmuleDeploy -Denvironment=$(environment) -Dapp.runtime=$(app.runtime) -DapplicationName=$(applicationName)'