mattwebbio / orbital-sync

Synchronize multiple Pi-hole instances
http://orbitalsync.com
MIT License
634 stars 20 forks source link

FetchError reason: connect ETIMEDOUT / ⚠ Failure: An unexpected error was thrown: #427

Open Kazer67 opened 1 month ago

Kazer67 commented 1 month ago

What happened?

Context:

I have two Pi-Hole:

both of them use a self-signed certificate with an HTTP to HTTPS redirection on lighttpd/1.4.69.

I'm using docker on the main Pi-Hole (192.168.1.15) with the following configuration (password redacted):

version: '3'
services:
  orbital-sync:
    image: mattwebbio/orbital-sync:1
    environment:
      PRIMARY_HOST_BASE_URL: 'https://192.168.1.15'
      PRIMARY_HOST_PASSWORD: '<password_main_pihole>'
      SECONDARY_HOSTS_1_BASE_URL: 'https://192.168.1.13'
      SECONDARY_HOSTS_1_PASSWORD: '<password_backup_pihole>'
      INTERVAL_MINUTES: 60

I have access to both Pi-Hole from another computer and I can curl from the main backup to its own admin page locally (when ignoring that the cert is selfsigned): curl -I --insecure https://192.168.1.13:443/admin :

dietpi@rasp-green:~/orbital-sync$ curl -I --insecure https://192.168.1.13:443/admin
HTTP/2 301 
location: /admin/
date: Mon, 09 Sep 2024 18:38:20 GMT
server: lighttpd/1.4.69

Orbital-sync try to connect from the main Pi to its own admin page and fail after a while with "⚠ Failure: An unexpected error was thrown:"

Version

V1.8.2

Log output

dietpi@rasp-green:~/orbital-sync$ docker compose up
WARN[0000] /home/dietpi/orbital-sync/docker-compose.yml: the attribute `version` is obsolete, it will be ignored, please remove it to avoid potential confusion 
[+] Running 1/0
 ✔ Container orbital-sync-orbital-sync-1  Created                                                                                                                                        0.0s 
Attaching to orbital-sync-1
orbital-sync-1  | 9/9/2024, 6:26:23 PM: ➡️ Signing in to https://192.168.1.15/admin...
orbital-sync-1  | 9/9/2024, 6:28:33 PM: ⚠ Failure: An unexpected error was thrown:
orbital-sync-1  | - FetchError: request to https://192.168.1.15/admin/index.php?login failed, reason: connect ETIMEDOUT 192.168.1.15:443
orbital-sync-1  | 9/9/2024, 6:28:33 PM: Waiting 60 minutes...
eko-hamburg commented 1 week ago

Same problem here. Would it be possible to add assistance for an environment variable that points to the self signing CAs certificate? Or just provide the possibility to ignore the certificate error. If possible after logging the used certificate to tell if really my selfsigned cert is used. Thank you.