This repository has been archived by the owner on Jan 12, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
build-base-and-push.groovy
95 lines (89 loc) · 3.19 KB
/
build-base-and-push.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
93
94
95
/*****************************************************************************
* *
* Copyright FUJITSU LIMITED 2020 *
* *
* Creation Date: 16-07-2020 *
* *
****************************************************************************/
/**
How to use:
1. Create a job of type Pipeline
2. As the pipeline script paste this script
3. Create the following parameters (adjust defaults as you wish):
Required environment variables:
===
Name: NODE_NAME
Type: Option list
Default: -
Description: Nodes used to run the pipeline.
===
Name: DOCKER_TAG
Type: String
Default: latest
Description: Docker tag name for created images
===
Name: DOCKER_REGISTRY
Type: String
Description: Registry host and port for the final Docker image. Example: <DOCKER_REGISTRY>/<DOCKER_ORGANIZATION>/oscm-core:<DOCKER_TAG>
===
Name: DOCKER_ORGANIZATION
Type: String
Default: oscmdocker
Description: Organization name for the final Docker image. Example: <DOCKER_REGISTRY>/<DOCKER_ORGANIZATION>/oscm-core:<DOCKER_TAG>
===
Name: REPO_TAG_OSCM
Type: String
Default: master
Description: Branch or tag in the oscm git repository: https://github.com/servicecatalog/oscm
===
Name: REPO_TAG_DOCKERBUILD
Type: String
Default: master
Description: Branch or tag in the oscm-dockerbuild git repository: https://github.com/servicecatalog/oscm-dockerbuild
===
Name: REPO_TAG_OSCM_APP
Type: String
Default: master
Description: Branch or tag in the oscm-app git repository: https://github.com/servicecatalog/oscm-app
===
Name: REPO_TAG_APP_SHELL
Type: String
Default: master
Description: Branch or tag in the oscm-app-shell git repository: https://github.com/servicecatalog/oscm-app-shell
===
Name: REPO_TAG_APPROVAL
Type: String
Default: master
Description: Branch or tag in the oscm-approval git repository: https://github.com/servicecatalog/oscm-approval
===
Name: REPO_TAG_IDENTITY
Type: String
Default: master
Description: Branch or tag in the oscm-identity git repository: https://github.com/servicecatalog/oscm-identity
===
Name: REPO_TAG_DOCUMENTATION
Type: String
Default: master
Description: Branch or tag in the documentation git repository" https://github.com/servicecatalog/documentation
===
Name: TRUSTED_CERTS_PATH
Type: String
Default: /opt/trusted_certs
Description: Path to the directory with certificates that will be imported as trusted by oscm
===
Name: COMPLETE_CLEANUP
Default: enabled
Description: Delete the database and whole workspace
===
**/
node("${NODE_NAME}") {
def clean = evaluate readTrusted('shared/cleanup.groovy')
def defVariables = evaluate readTrusted('shared/proxyvariables.groovy')
def build = evaluate readTrusted('shared/build-base.groovy')
def push = evaluate readTrusted('shared/push.groovy')
def IMAGES="db birt branding help maildev proxy gf"
clean.execute()
defVariables.execute()
build.execute()
push.execute(true, false, IMAGES)
}