Skip to content

[Install help] Connectivity issue: paperless-ai to -ngx API behind Traefik #468

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
snl-r opened this issue Apr 13, 2025 · 1 comment
Open

Comments

@snl-r
Copy link

snl-r commented Apr 13, 2025

My paperless-ai (/setup) does not connect to paperless-ngx. This is on a dedicated remote server. NGX is running fine, behind Traefik (Pangolin). In NGX, I created an API key for the user and provided URL/user/key on the -ai /setup page. Error message in the GUI is "Failed to initialize connection to Paperless-ngx. Please check URL and Token." and docker logs -f paperless-ai = "[ERROR] Failed to initialize with credentials: connect ECONNREFUSED myIP:443" ... this looks like a CORS error maybe, since the creds are definitely ok, but in NGX docker_compose.env I already set PAPERLESS_URL=myURL, and also PAPERLESS_CSRF_TRUSTED_ORIGINS and PAPERLESS_ALLOWED_HOSTS and PAPERLESS_CORS_ALLOWED_HOSTS each to myUrl,aiURL,llmURL and restarted - the error remains the same. Pangolin does add SSO, and I added some rules (always allow from ai domain), and disabling SSO alltogether makes no difference either. What else could I be missing?

@snl-r
Copy link
Author

snl-r commented Apr 13, 2025

Am I supposed to NOT do this via the exposed URLs, but docker-to-docker instead? All three, Pangolin (Traefik), paperless-ngx, and paperless-ai are on the same VM. However, I'm looking at https://ai.mydomain.com/setup and local URIs don't work out either.

With local/internal IPs in the /setup form, and also adding them in CSRF/CORS params in paperless-ngx' docker-compose.env, the error in docker logs -f paperless-ai changes to "[ERROR] Failed to initialize with credentials: read ECONNRESET"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant