You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+49-10Lines changed: 49 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -55,11 +55,11 @@ npm unlink .
55
55
### Building Docker Image
56
56
57
57
```sh
58
-
docker build -t servicenowdocker/sndevops:6.0.0 .
58
+
docker build -t servicenowdocker/sndevops:6.2.0 .
59
59
```
60
60
61
61
```sh
62
-
docker push servicenowdocker/sndevops:6.0.0
62
+
docker push servicenowdocker/sndevops:6.2.0
63
63
```
64
64
65
65
## Integrating with GitLab
@@ -95,6 +95,42 @@ COMMIT_BRANCH: <commit-branch>
95
95
WORKFLOW_NAME: <workflow-name>
96
96
```
97
97
98
+
### Proxy Configuration (Optional)
99
+
100
+
If your ServiceNow instance is behind a proxy or you need to route requests through a proxy server, you can configure the following environment variables:
101
+
102
+
```
103
+
PROXY_ENDPOINT: <proxy-url> # e.g., http://localhost:7080 or https://proxy.example.com:8080
104
+
PROXY_USERNAME: <proxy-username> # Optional: for proxy authentication
105
+
PROXY_PASSWORD: <proxy-password> # Optional: for proxy authentication
106
+
PROXY_AUTH: <proxy-api-key> # Optional: alternative authentication using API key
107
+
```
108
+
109
+
**Notes:**
110
+
-`PROXY_ENDPOINT` can be either HTTP or HTTPS
111
+
- For backward compatibility, `HTTP_PROXY` and `HTTPS_PROXY` are also supported as fallback options
112
+
- If using self-signed certificates with HTTPS proxy, set `NODE_TLS_REJECT_UNAUTHORIZED=0` (for testing only)
113
+
- Authentication can be provided via:
114
+
- Username/Password: Use `PROXY_USERNAME` and `PROXY_PASSWORD`
115
+
- API Key: Use `PROXY_AUTH`
116
+
- No authentication: Leave authentication variables unset
117
+
118
+
**Example with proxy:**
119
+
```yaml
120
+
stages:
121
+
- package
122
+
123
+
package:
124
+
stage: package
125
+
image: servicenowdocker/sndevops:6.2.0
126
+
variables:
127
+
PROXY_ENDPOINT: "https://proxy.example.com:8080"
128
+
PROXY_USERNAME: "proxy_user"
129
+
PROXY_PASSWORD: "proxy_pass"
130
+
script:
131
+
- sndevopscli create package -n "package-name" -a '[{"name":"artifact-name","repositoryName":"artifact-repo-name","version":"1.3.0"}]'
132
+
```
133
+
98
134
**Example with passing all ServiceNow information via commandline**
99
135
```yaml
100
136
@@ -105,7 +141,7 @@ stages:
105
141
106
142
package:
107
143
stage: package
108
-
image: servicenowdocker/sndevops:6.0.0
144
+
image: servicenowdocker/sndevops:6.2.0
109
145
script:
110
146
- sndevopscli create artifact -a '[{"name":"artifact-name","repositoryName":"artifact-repo-name" ,"version":"1.3.0"}]'
111
147
- sndevopscli create package -n "package-name" -a '[{"name":"artifact-name","repositoryName":"artifact-repo-name" ,"version":"1.3.0"}]
- sndevopscli create change -p '{"changeStepDetails":{"timeout":3600,"interval":100},"attributes":{"short_description":"Automated Software Deployment","description":"Automated Software Deployment.","assignment_group":"XXXXXXX","implementation_plan":"Software update is tested and results can be found in Test Summaries Tab.","backout_plan":"When software fails in production, the previous software release will be re-deployed.","test_plan":"Testing if the software was successfully deployed or not"}}'
- sndevopscli get change -p "{\"buildNumber\":\"buildNumber\",\"stageName\":\"ServiceNow DevOps Change Step\",\"pipelineName\":\"GitlabDockerGetAndUpdateChange\"}"
240
276
@@ -246,6 +282,9 @@ This specifies ID of the Job where we have created change request.
246
282
stageName: [mandatory]
247
283
This specifies the Job name where we have created change request..
248
284
285
+
pipelineExecutionId: [optional]
286
+
This specifies the Pipeline Execution Id(Running ID of the pipeline)..
287
+
249
288
pipelineName: [mandatory]
250
289
This specifies the pipeline name.
251
290
@@ -270,7 +309,7 @@ stages:
270
309
271
310
ServiceNow DevOps Update Change:
272
311
stage: DevOpsUpdateChangeStage
273
-
image: servicenowdocker/sndevops:6.0.0
312
+
image: servicenowdocker/sndevops:6.2.0
274
313
script:
275
314
- sndevopscli update change -n 'CHGXXXXXX' -p "{\"short_description\":\"Automated Software Deployment\",\"description\":\"Automated Software Deployment.\",\"assignment_group\":\"XXXXX\",\"implementation_plan\":\"Software update is tested and results can be found in Test Summaries Tab.\",\"backout_plan\":\"When software fails in production, the previous software release will be re-deployed.\",\"test_plan\":\"Testing if the software was successfully deployed or not\"}"
276
315
@@ -297,7 +336,7 @@ stages:
297
336
298
337
ServiceNow DevOps Change Step:
299
338
stage: changeapproval
300
-
image: servicenowdocker/sndevops:6.0.0
339
+
image: servicenowdocker/sndevops:6.2.0
301
340
script:
302
341
- sndevopscli create change -p "{\"changeStepDetails\":{\"timeout\":3600,\"interval\":100},\"autoCloseChange\":true,\"attributes\":{\"short_description\":\"Automated Software Deployment\",\"description\":\"Automated Software Deployment.\",\"assignment_group\":\"xxxxxxxx\",\"implementation_plan\":\"Software update is tested and results can be found in Test Summaries Tab.\",\"backout_plan\":\"When software fails in production, the previous software release will be re-deployed.\",\"test_plan\":\"Testing if the software was successfully deployed or not\"}}"
0 commit comments