Use a macro to get the ips of the app/worker servers for the cache/queue/db firewall rules.
Remove non-working replication settings in the pg_hba.