在 PostgreSQLContainer 中设置 max_prepared_transactions

Set max_prepared_transactions in PostgreSQLContainer

可以在PostgreSQLContainer中设置max_prepared_transactions吗?

目前我通过构建新的 docker postgres 图像来解决,如下所示:

FROM postgres:10 RUN sed -ri "s!^#?(max_prepared_transactions)\s*=.*! = 110!" /usr/share/postgresql/postgresql.conf.sample

source