forked from hmcts/pcq-frontend
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Jenkinsfile_nightly
38 lines (32 loc) · 956 Bytes
/
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
#!groovy
properties([
// H allow predefined but random minute see https://en.wikipedia.org/wiki/Cron#Non-standard_characters
pipelineTriggers([cron('H 05 * * *')]),
parameters([
string(name: 'URL_TO_TEST', defaultValue: 'http://pcq-frontend-staging.service.core-compute-aat.internal', description: 'The URL you want to run these tests against'),
])
])
@Library("Infrastructure")
def type = "nodejs"
def product = "pcq"
def component = "frontend"
def secrets = [
'pcq-${env}': [
secret('jwt-secret', 'JWT_SECRET')
]
]
static LinkedHashMap<String, Object> secret(String secretName, String envVar) {
[ $class: 'AzureKeyVaultSecret',
secretType: 'Secret',
name: secretName,
version: '',
envVariable: envVar
]
}
withNightlyPipeline(type, product, component) {
env.TEST_URL = params.URL_TO_TEST
loadVaultSecrets(secrets)
enableMutationTest();
enableSlackNotifications('#pcq-builds')
enableSecurityScan()
}