We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a41c33e commit 39c281dCopy full SHA for 39c281d
1 file changed
utility/troubleshooting/gitlab_requests.py
@@ -0,0 +1,13 @@
1
+"""
2
+helper script to try out request to private gitlab repo, as referenced in Quali custom script driver
3
+https://github.com/QualiSystems/CustomScript-Shell/blob/877d0df447bf513088779d247116087ee14f63a4/package/cloudshell/cm/customscript/domain/script_downloader.py#L75
4
5
+
6
+import requests
7
8
+TOKEN = "MY_TOKEN"
9
+URL = "MY_URL"
10
+headers = {"Private-Token": f"Bearer {TOKEN}"}
11
+response = requests.get(URL, stream=True, headers=headers, verify=False)
12
+print(f"Response code: {response.status_code}")
13
+print(f"Response text:\n{response.text}")
0 commit comments