server.yml 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. # ntfy server config file
  2. # Public facing base URL of the service (e.g. https://ntfy.sh or https://ntfy.example.com)
  3. # This setting is currently only used by the attachments and e-mail sending feature (outgoing mail only).
  4. #
  5. # base-url:
  6. # Listen address for the HTTP & HTTPS web server. If "listen-https" is set, you must also
  7. # set "key-file" and "cert-file". Format: [<ip>]:<port>, e.g. "1.2.3.4:8080".
  8. #
  9. # To listen on all interfaces, you may omit the IP address, e.g. ":443".
  10. # To disable HTTP, set "listen-http" to "-".
  11. #
  12. # listen-http: ":80"
  13. # listen-https:
  14. # Listen on a Unix socket, e.g. /var/lib/ntfy/ntfy.sock
  15. # This can be useful to avoid port issues on local systems, and to simplify permissions.
  16. #
  17. # listen-unix: <socket-path>
  18. # Path to the private key & cert file for the HTTPS web server. Not used if "listen-https" is not set.
  19. #
  20. # key-file:
  21. # cert-file:
  22. # If set, also publish messages to a Firebase Cloud Messaging (FCM) topic for your app.
  23. # This is optional and only required to save battery when using the Android app.
  24. #
  25. # firebase-key-file: <filename>
  26. # If set, messages are cached in a local SQLite database instead of only in-memory. This
  27. # allows for service restarts without losing messages in support of the since= parameter.
  28. #
  29. # To disable the cache entirely (on-disk/in-memory), set "cache-duration" to 0.
  30. # The cache file is created automatically, provided that the correct permissions are set.
  31. #
  32. # Debian/RPM package users:
  33. # Use /var/cache/ntfy/cache.db as cache file to avoid permission issues. The package
  34. # creates this folder for you.
  35. #
  36. # Check your permissions:
  37. # If you are running ntfy with systemd, make sure this cache file is owned by the
  38. # ntfy user and group by running: chown ntfy.ntfy <filename>.
  39. #
  40. # cache-file: <filename>
  41. # Duration for which messages will be buffered before they are deleted.
  42. # This is required to support the "since=..." and "poll=1" parameter.
  43. #
  44. # You can disable the cache entirely by setting this to 0.
  45. #
  46. # cache-duration: "12h"
  47. # If set, the X-Forwarded-For header is used to determine the visitor IP address
  48. # instead of the remote address of the connection.
  49. #
  50. # WARNING: If you are behind a proxy, you must set this, otherwise all visitors are rate limited
  51. # as if they are one.
  52. #
  53. # behind-proxy: false
  54. # If enabled, clients can attach files to notifications as attachments. Minimum settings to enable attachments
  55. # are "attachment-cache-dir" and "base-url".
  56. #
  57. # - attachment-cache-dir is the cache directory for attached files
  58. # - attachment-total-size-limit is the limit of the on-disk attachment cache directory (total size)
  59. # - attachment-file-size-limit is the per-file attachment size limit (e.g. 300k, 2M, 100M)
  60. # - attachment-expiry-duration is the duration after which uploaded attachments will be deleted (e.g. 3h, 20h)
  61. #
  62. # attachment-cache-dir:
  63. # attachment-total-size-limit: "5G"
  64. # attachment-file-size-limit: "15M"
  65. # attachment-expiry-duration: "3h"
  66. # If enabled, allow outgoing e-mail notifications via the 'X-Email' header. If this header is set,
  67. # messages will additionally be sent out as e-mail using an external SMTP server. As of today, only
  68. # SMTP servers with plain text auth and STARTLS are supported. Please also refer to the rate limiting settings
  69. # below (visitor-email-limit-burst & visitor-email-limit-burst).
  70. #
  71. # - smtp-sender-addr is the hostname:port of the SMTP server
  72. # - smtp-sender-user/smtp-sender-pass are the username and password of the SMTP user
  73. # - smtp-sender-from is the e-mail address of the sender
  74. #
  75. # smtp-sender-addr:
  76. # smtp-sender-user:
  77. # smtp-sender-pass:
  78. # smtp-sender-from:
  79. # If enabled, ntfy will launch a lightweight SMTP server for incoming messages. Once configured, users can send
  80. # emails to a topic e-mail address to publish messages to a topic.
  81. #
  82. # - smtp-server-listen defines the IP address and port the SMTP server will listen on, e.g. :25 or 1.2.3.4:25
  83. # - smtp-server-domain is the e-mail domain, e.g. ntfy.sh
  84. # - smtp-server-addr-prefix is an optional prefix for the e-mail addresses to prevent spam. If set to "ntfy-",
  85. # for instance, only e-mails to ntfy-$topic@ntfy.sh will be accepted. If this is not set, all emails to
  86. # $topic@ntfy.sh will be accepted (which may obviously be a spam problem).
  87. #
  88. # smtp-server-listen:
  89. # smtp-server-domain:
  90. # smtp-server-addr-prefix:
  91. # Interval in which keepalive messages are sent to the client. This is to prevent
  92. # intermediaries closing the connection for inactivity.
  93. #
  94. # Note that the Android app has a hardcoded timeout at 77s, so it should be less than that.
  95. #
  96. # keepalive-interval: "45s"
  97. # Interval in which the manager prunes old messages, deletes topics
  98. # and prints the stats.
  99. #
  100. # manager-interval: "1m"
  101. # Rate limiting: Total number of topics before the server rejects new topics.
  102. #
  103. # global-topic-limit: 15000
  104. # Rate limiting: Number of subscriptions per visitor (IP address)
  105. #
  106. # visitor-subscription-limit: 30
  107. # Rate limiting: Allowed GET/PUT/POST requests per second, per visitor:
  108. # - visitor-request-limit-burst is the initial bucket of requests each visitor has
  109. # - visitor-request-limit-replenish is the rate at which the bucket is refilled
  110. #
  111. # visitor-request-limit-burst: 60
  112. # visitor-request-limit-replenish: "10s"
  113. # Rate limiting: Allowed emails per visitor:
  114. # - visitor-email-limit-burst is the initial bucket of emails each visitor has
  115. # - visitor-email-limit-replenish is the rate at which the bucket is refilled
  116. #
  117. # visitor-email-limit-burst: 16
  118. # visitor-email-limit-replenish: "1h"
  119. # Rate limiting: Attachment size and bandwidth limits per visitor:
  120. # - visitor-attachment-total-size-limit is the total storage limit used for attachments per visitor
  121. # - visitor-attachment-daily-bandwidth-limit is the total daily attachment download/upload traffic limit per visitor
  122. #
  123. # visitor-attachment-total-size-limit: "100M"
  124. # visitor-attachment-daily-bandwidth-limit: "500M"