Skip to content

PostgreSQL should use model configs juju-http-proxy/juju-https-proxy/juju-no-proxy for backups #1098

@mcarvalhor

Description

@mcarvalhor

Hi everyone! 👋

Currently for backups, we integrate the charm with s3-integrator and then the charm communicates with the S3 endpoint directly.

Instead, the charm should use the model configs juju-http-proxy/juju-https-proxy/juju-no-proxy and use a HTTP proxy to communicate with the S3 endpoint, if those are set.

Steps to reproduce

  1. juju model-config juju-http-proxy="http://my-proxy.internal:3128" # Example
  2. juju model-config juju-https-proxy="http://my-proxy.internal:3128" # Example
  3. juju model-config juju-no-proxy="127.0.0.1,localhost,::1,10.1.0.0/16" # Example
  4. juju deploy postgresql --channel="14/stable" -n 3
  5. juju deploy s3-integrator
  6. juju relate s3-integrator postgresql
  7. juju run s3-integrator sync-s3-credentials access-key="..." secret-key="..."

Expected behavior

Communication to S3 happens via a proxy set using Juju Model Configs juju-http-proxy/juju-https-proxy/juju-no-proxy.

Actual behavior

PostgreSQL try to perform the backups by connecting directly to the S3 endpoint, not using the proxy:
https://pastebin.canonical.com/p/VT8nVCsb7q/

Versions

Operating system: Ubuntu 24.04

Juju CLI: 3.6.8-ubuntu-amd64

Juju agent: 3.6.8

Charm revision: 14/stable - 553

LXD: N/A (using Openstack)

Log output

https://pastebin.canonical.com/p/VT8nVCsb7q/

Additional context

This is a blocker for all PostgreSQL deployments on PS7, PS8+.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature, UI change, or workload upgrade

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions