-
Notifications
You must be signed in to change notification settings - Fork 9
/
Jenkinsfile_CNP
44 lines (37 loc) · 1.06 KB
/
Jenkinsfile_CNP
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
#!groovy
import uk.gov.hmcts.contino.AppPipelineDsl
def secrets = [
's2s-${env}':
[
secret('jwt-key', 'JWTKEY'),
secret('microservicekey-send-letter-tests', 'TEST_SERVICE_SECRET')
]
]
static LinkedHashMap<String, Object> secret(String secretName, String envVar) {
[ $class: 'AzureKeyVaultSecret',
secretType: 'Secret',
name: secretName,
version: '',
envVariable: envVar
]
}
@Library("Infrastructure")
def type = "java"
def product = "rpe"
def component = "service-auth-provider"
def expiresAfter = "3000-01-01"
// Vars for Kubernetes
def branchesToSync = ['demo', 'perftest', 'ithc']
withPipeline(type, product, component) {
env.TEST_SERVICE_NAME = "send_letter_tests"
enableSlackNotifications('#platops-build-notices')
loadVaultSecrets(secrets)
enableAksStagingDeployment()
disableLegacyDeployment()
syncBranchesWithMaster(branchesToSync)
expires(expiresAfter)
onMaster() {
env.PACT_BRANCH_NAME = "master"
enablePactAs([AppPipelineDsl.PactRoles.PROVIDER])
}
}