Added
- Optional Native TLS (
rediss://) & mTLS (src/tls.rs, src/worker.rs, src/config.rs):
- Strictly opt-in via
pg_redis.tls_port (default 0, disabled) so plain non-TLS TCP on port 6379 continues working unchanged by default.
- Supports all three deployment modes:
- Plain TCP only (default):
pg_redis.port = 6379, pg_redis.tls_port = 0.
- Dual-port (Plain TCP + TLS simultaneously):
pg_redis.port = 6379, pg_redis.tls_port = 6380 with pg_redis.tls_cert_file and pg_redis.tls_key_file.
- TLS-only (Encrypted only):
pg_redis.port = 0, pg_redis.tls_port = 6380 (mirrors Redis port 0 + tls-port).
- Optional mutual TLS (mTLS) client certificate authentication via
pg_redis.tls_ca_cert_file and pg_redis.tls_auth_clients (no | optional | yes).
- Built on pure-Rust
tokio-rustls + ring (TLS 1.2 & TLS 1.3) to avoid OpenSSL/libssl symbol conflicts with PostgreSQL, with non-blocking 10-second handshake timeouts so stalled handshakes never affect other clients.
- Live Certificate Hot-Reload on
SIGHUP: SELECT pg_reload_conf(); reloads pg_redis.tls_cert_file, pg_redis.tls_key_file, pg_redis.tls_ca_cert_file, and pg_redis.tls_auth_clients without restarting PostgreSQL (keeping the previous working configuration on reload error).
- Exposed
tls_port in INFO # Server and tls-port / tls-auth-clients in CONFIG GET.
- Upgrade Script & E2E Tests:
- Added
sql/pg_redis_core--0.4.1--0.5.0.sql.
- Added
tests/test_v050_tls.sh and tests/clients/pubsub/test_tls.mjs verifying dual-port mode (ioredis + redis-cli --tls, cross-transport Pub/Sub, BZPOPMIN over TLS, plaintext rejection on TLS port), TLS-only + mTLS enforcement, and live SIGHUP certificate hot-reload, plus #[pg_test] opt-in default checks.
Prebuilt Extension Binaries (SHA-256)
0bb7a8efb5ba9b70478d006d6146e911a4c02462e1231fe4483df177f3b6a1e9 pg_redis_core-0.5.0-pg15-linux-amd64.tar.gz
56dfef12fe80defccf7fb734db4a58926b191136d29c9a97cbc91d147892b0ed pg_redis_core-0.5.0-pg15-linux-arm64.tar.gz
7a22435c6ccc29ed58821a71e7607b94fb5e60d516b559d7feb2ad1eb2086fe5 pg_redis_core-0.5.0-pg16-linux-amd64.tar.gz
e40888930efa3f0514cab6e8b57cd49343ad433641e569cefa2c24fb54055d27 pg_redis_core-0.5.0-pg16-linux-arm64.tar.gz
Docker Images (Multi-Arch: linux/amd64, linux/arm64)
# PostgreSQL 15
docker pull ghcr.io/megacoderkim/pg2redis:v0.5.0-pg15
# PostgreSQL 16
docker pull ghcr.io/megacoderkim/pg2redis:v0.5.0-pg16
Documentation
https://megacoderkim.github.io/pg2redis/