tractr / directus-sync

A CLI tool for synchronizing the schema and configuration of Directus across various environments.
GNU General Public License v3.0
241 stars 10 forks source link

fetch failed: self-signed certificate #16

Closed cedenoVF closed 9 months ago

cedenoVF commented 10 months ago

Hi,

We are using self hosted Directus:

Directus version: 10.8.3 Self hosted:

image

To replicate the error run Directus in a self-hosted with a self-signed certificate using HTTPS.

The call "pull" : npx directus-sync pull --config-path './directus-sync.config.cjs'

image

The device is in our intranet.. We got our own domain server, so we put the domain directly in the config.

This is our config

Thanks in advance :)

EdouardDem commented 9 months ago

Hi @cedenoVF, You can try to bypass SSL verification by passing environment NODE_TLS_REJECT_UNAUTHORIZED=0 to Node :

NODE_TLS_REJECT_UNAUTHORIZED=0 npx directus-sync pull --config-path './directus-sync.config.cjs'
EdouardDem commented 9 months ago

@cedenoVF I just publish a new version that handles the ./directus-sync.config.cjs config file path by default.

https://github.com/tractr/directus-sync/pull/24

cedenoVF commented 9 months ago

Hi, Thank you for the notification :) noted, We will try later (after we talk about other "issue" )