amyasnikov / validity

NetBox plugin to validate network devices
MIT License
136 stars 8 forks source link

How to disable ssl sertificate check in Git Repo #65

Closed ArsenyPie closed 9 months ago

ArsenyPie commented 9 months ago

Hi, i'm using clone a repo from an internal server which holds a self-signed certificate. The Git Repositories module throws a certificate verification error when trying to synchronize. How do I turn the verification off? I'm still new to programming and automation, so after studying similar problems of other users in the pygit2 module branch, I didn't understand what exactly needs to be fixed. That's why I'm writing here.... (>^.^)>

amyasnikov commented 9 months ago

Hey @ArsenyPie, Unfortunately it's not possible right now and to be honest I don't see a lot of sense in implementing this feature because version 2.0 is very close to be released (I still need 1-2 weeks to do the docs for it). In this version Git Repositories are completely removed in favor of NetBox Data Sources.

I'm not sure if this issue persists for Data Sources. Check out this one: https://github.com/netbox-community/netbox/issues/13989#issuecomment-1751008736 Maybe adding your root CA to the system and using NetBox 3.6.3+ might help (for me it's not very clear from author's posts)

Fredouye commented 6 months ago

Hi

I'm running Netbox with Docker Compose, I just had to add this to the docker-compose.override.yml file :

services:
  netbox-worker:
    volumes:
      - /indus/pki/ca.crt:/etc/ssl/certs/ca.crt:ro
    environment:
      SSL_CERT_FILE: /etc/ssl/certs/ca.crt

Using this configuration, I can clone from an internal GitLab repository.