This repository has been archived by the owner on May 25, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathJenkinsfile_nightly
75 lines (64 loc) · 2.84 KB
/
Jenkinsfile_nightly
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
#!groovy
properties([
pipelineTriggers([cron('H 05 * * *')]),
parameters([
string(name: 'FRONTEND_URL', defaultValue: 'https://manage-case.aat.platform.hmcts.net',
description: 'The URL you want to run the full functional tests against'),
string(name: 'CASE_SERVICE_URL', defaultValue: 'http://civil-damages-service-aat.service.core-compute-aat.internal',
description: 'The URL of case service callbacks'),
string(name: 'IDAM_API_URL', defaultValue: 'https://idam-api.aat.platform.hmcts.net',
description: 'The URL of idam api'),
string(name: 'DM_STORE_URL', defaultValue: 'http://dm-store-aat.service.core-compute-aat.internal',
description: 'The URL of dm store'),
string(name: 'SERVICE_AUTH_PROVIDER_API_BASE_URL', defaultValue: 'http://rpe-service-auth-provider-aat.service.core-compute-aat.internal',
description: 'The URL of service auth provider'),
string(name: 'CCD_DATA_STORE_URL', defaultValue: 'http://ccd-data-store-api-aat.service.core-compute-aat.internal',
description: 'The URL of ccd data store'),
string(name: 'UNSPEC_SERVICE_URL', defaultValue: 'http://civil-damages-service-aat.service.core-compute-aat.internal',
description: 'The URL of unspec service'),
string(name: 'WAIT_FOR_TIMEOUT_MS',
defaultValue: '120000',
description: 'Functional tests waitForTimeout value'),
string(name: 'SECURITY_RULES',
defaultValue: 'https://raw.githubusercontent.com/hmcts/security-test-rules/master/conf/security-rules.conf',
description: 'The security rules to use'),
string(name: 'FUNCTIONAL_TESTS_WORKERS',
defaultValue: '1',
description: 'Number of workers running functional tests'),
])
])
@Library("Infrastructure")
def type = "java"
def product = "civil-damages"
def component = "service"
static Map<String, Object> secret(String secretName, String envVariable) {
[$class : 'AzureKeyVaultSecret',
secretType : 'Secret',
name : secretName,
envVariable: envVariable
]
}
def secrets = [
'unspec-${env}': [
secret('microservicekey-unspec-service', 'S2S_SECRET')
]
]
withNightlyPipeline(type, product, component) {
env.URL = params.FRONTEND_URL
env.DM_STORE_URL=params.DM_STORE_URL
env.IDAM_API_URL=params.IDAM_API_URL
env.CASE_SERVICE_URL=params.CASE_SERVICE_URL
env.SERVICE_AUTH_PROVIDER_API_BASE_URL = params.SERVICE_AUTH_PROVIDER_API_BASE_URL
env.CCD_DATA_STORE_URL = params.CCD_DATA_STORE_URL
env.UNSPEC_SERVICE_URL = params.UNSPEC_SERVICE_URL
env.WAIT_FOR_TIMEOUT_MS = params.WAIT_FOR_TIMEOUT_MS
env.URL_FOR_SECURITY_SCAN = params.CASE_SERVICE_URL
loadVaultSecrets(secrets)
//enableMutationTest()
enableSecurityScan()
enableFullFunctionalTest(200)
after('fullFunctionalTest') {
sh """ ./gradlew runRpaHandOffTests """
archiveArtifacts allowEmptyArchive: true, artifacts: 'output/**/*'
}
}