-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathrhtap.groovy
92 lines (71 loc) · 1.99 KB
/
rhtap.groovy
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
/* Generated from templates/rhtap.groovy.njk. Do not edit directly. */
def info(message) {
echo "INFO: ${message}"
}
def install_script (scriptname) {
echo ("Loading libraryResource(${scriptname})")
contents = libraryResource( scriptname )
writeFile(file: "rhtap/${scriptname}" , text: contents)
sh "chmod +x rhtap/${scriptname}"
}
def run_script (scriptname) {
// load common utilities across all tasks
install_script ("common.sh")
install_script ("verify-deps-exist")
if (scriptname == 'buildah-rhtap.sh') {
// Called from buildah-rhtap.sh
install_script ('merge_sboms.py')
}
if (scriptname == 'cosign-sign-attest.sh') {
// Called from cosign-sign-attest.sh
install_script ('att-predicate-jenkins.sh')
}
if (scriptname == 'gather-images-to-upload-sbom.sh') {
// Called from gather-images-to-upload-sbom.sh
install_script ('gather-deploy-images.sh')
}
install_script (scriptname)
sh "rhtap/${scriptname}"
}
def init( ) {
run_script ('init.sh')
}
def buildah_rhtap( ) {
run_script ('buildah-rhtap.sh')
}
def cosign_sign_attest( ) {
run_script ('cosign-sign-attest.sh')
}
def acs_deploy_check( ) {
run_script ('acs-deploy-check.sh')
}
def acs_image_check( ) {
run_script ('acs-image-check.sh')
}
def acs_image_scan( ) {
run_script ('acs-image-scan.sh')
}
def update_deployment( ) {
run_script ('update-deployment.sh')
}
def show_sbom_rhdh( ) {
run_script ('show-sbom-rhdh.sh')
}
def summary( ) {
run_script ('summary.sh')
}
def gather_deploy_images( ) {
run_script ('gather-deploy-images.sh')
}
def verify_enterprise_contract( ) {
run_script ('verify-enterprise-contract.sh')
}
def gather_images_to_upload_sbom( ) {
run_script ('gather-images-to-upload-sbom.sh')
}
def download_sbom_from_url_in_attestation( ) {
run_script ('download-sbom-from-url-in-attestation.sh')
}
def upload_sbom_to_trustification( ) {
run_script ('upload-sbom-to-trustification.sh')
}