idealista / prom2teams

prom2teams is an HTTP server built with Python that receives alert notifications from a previously configured Prometheus Alertmanager instance and forwards it to Microsoft Teams using defined connectors
Apache License 2.0
274 stars 85 forks source link

[SUPPORT] Configuring Proxy (Docker Image) #319

Closed Oleksandr-Nikiha closed 1 year ago

Oleksandr-Nikiha commented 1 year ago

Description

How do I configure the proxy correctly if I'm using a Docker image?

But something is not working

Additional Information

Return log: requests.exceptions.ConnectionError: HTTPSConnectionPool(host='****.webhook.office.com', port=443): Max retries exceeded with url: ... (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x7f48ece8ab20>: Failed to establish a new connection: [Errno 101] Network unreachable'))

Although there is access from this client to sources through a proxy.

Currently, in docker-compose.yml, the settings look like this:


prom2teams:
  image: idealista/prom2teams
  container_name: prom2teams
  restart: unless-stopped
  environment:
    PROM2TEAMS_CONNECTOR: 'https://****.webhook.office.com/webhookb2/...'
    PROM2TEAMS_EXTRAENV: 'http_proxy=http://login:pass@proxy_address:proxy_port HTTP_PROXY=http://login:pass@proxy_address:proxy_port https_proxy=http://login:pass@proxy_address:proxy_port HTTPS_PROXY=http://login:pass@proxy_address:proxy_port'
  ports:
    - '8089:8089'
  networks:
    - monitoring
stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.