You've already forked postgres
mirror of
https://github.com/docker-library/postgres.git
synced 2025-11-17 13:02:40 +03:00
Change default STOPSIGNAL from SIGTERM to SIGINT
This commit is contained in:
committed by
Tianon Gravi
parent
09c342c555
commit
bfc5d81c8f
@@ -184,5 +184,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -148,5 +148,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -184,5 +184,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -150,5 +150,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -184,5 +184,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -149,5 +149,35 @@ VOLUME /var/lib/postgresql/data
|
|||||||
COPY docker-entrypoint.sh /usr/local/bin/
|
COPY docker-entrypoint.sh /usr/local/bin/
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -186,5 +186,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -149,5 +149,35 @@ VOLUME /var/lib/postgresql/data
|
|||||||
COPY docker-entrypoint.sh /usr/local/bin/
|
COPY docker-entrypoint.sh /usr/local/bin/
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -185,5 +185,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -146,5 +146,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -185,5 +185,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -146,5 +146,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -150,5 +150,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
@@ -187,5 +187,35 @@ COPY docker-entrypoint.sh /usr/local/bin/
|
|||||||
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
|
||||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||||
|
|
||||||
|
# We set the default STOPSIGNAL to SIGINT, which corresponds to what PostgreSQL
|
||||||
|
# calls "Fast Shutdown mode" wherein new connections are disallowed and any
|
||||||
|
# in-progress transactions are aborted, allowing PostgreSQL to stop cleanly and
|
||||||
|
# flush tables to disk, which is the best compromise available to avoid data
|
||||||
|
# corruption.
|
||||||
|
#
|
||||||
|
# Users who know their applications do not keep open long-lived idle connections
|
||||||
|
# may way to use a value of SIGTERM instead, which corresponds to "Smart
|
||||||
|
# Shutdown mode" in which any existing sessions are allowed to finish and the
|
||||||
|
# server stops when all sessions are terminated.
|
||||||
|
#
|
||||||
|
# See https://www.postgresql.org/docs/12/server-shutdown.html for more details
|
||||||
|
# about available PostgreSQL server shutdown signals.
|
||||||
|
#
|
||||||
|
# See also https://www.postgresql.org/docs/12/server-start.html for further
|
||||||
|
# justification of this as the default value, namely that the example (and
|
||||||
|
# shipped) systemd service files use the "Fast Shutdown mode" for service
|
||||||
|
# termination.
|
||||||
|
#
|
||||||
|
STOPSIGNAL SIGINT
|
||||||
|
#
|
||||||
|
# An additional setting that is recommended for all users regardless of this
|
||||||
|
# value is the runtime "--stop-timeout" (or your orchestrator/runtime's
|
||||||
|
# equivalent) for controlling how long to wait between sending the defined
|
||||||
|
# STOPSIGNAL and sending SIGKILL (which is likely to cause data corruption).
|
||||||
|
#
|
||||||
|
# The default in most runtimes (such as Docker) is 10 seconds, and the
|
||||||
|
# documentation at https://www.postgresql.org/docs/12/server-start.html notes
|
||||||
|
# that even 90 seconds may not be long enough in many instances.
|
||||||
|
|
||||||
EXPOSE 5432
|
EXPOSE 5432
|
||||||
CMD ["postgres"]
|
CMD ["postgres"]
|
||||||
|
|||||||
Reference in New Issue
Block a user