Remote Data Source Git HTTPS - SSLCertVerificationError #15180
Unanswered
UMRNOC
asked this question in
Help Wanted!
Replies: 1 comment 1 reply
-
Did you manage to do something ? We are looking at the same problem here. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Deployment Type
Self-hosted
NetBox Version
v3.7.2
Python Version
3.10
Steps to Reproduce
Click on Operations
Click on Data Sources
Add a new data source
set a name
choose type Git
add URL (https)
add username, password and branch
click on create
Now click on Sync
Expected Behavior
Sync should work.
Self signed Root Certificate was added via "update-ca-certificates" in Ubuntu.
Observed Behavior
SyncError("Fetching remote data failed (GitProtocolError): HTTPSConnectionPool(host='git.domain.local', port=443): Max retries exceeded with url: /Network/netbox.git/info/refs?service=git-upload-pack (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1007)')))")
Output of manage.py syncdatasource --all --traceback:
If i change netbox/core/data_backends.py to:
# Apply HTTP proxy (if configured)
if settings.HTTP_PROXIES and self.url_scheme in ('http', 'https'):
if proxy := settings.HTTP_PROXIES.get(self.url_scheme):
config.set("http", "proxy", proxy)
config.set("http", "sslCAInfo", "/etc/ssl/certs/myRootCA.crt")
Sync button in Web GUI is reporting the same error.
But "manage.py syncdatasource --all --traceback" is giving me:
[1] Syncing git.domain.local netbox repo... Completed
Beta Was this translation helpful? Give feedback.
All reactions