1 -- Prosody Configuration File
3 -- Information on configuring Prosody can be found on our
4 -- website at https://prosody.im/doc/configure
6 -- Tip: You can check that the syntax of this file is correct
7 -- when you have finished by running this command:
8 -- prosodyctl check config
9 -- If there are any errors, it will let you know what and where
10 -- they are, otherwise it will keep quiet.
12 -- The only thing left to do is rename this file to remove the .dist ending, and fill in the
13 -- blanks. Good luck, and happy Jabbering!
16 ---------- Server-wide settings ----------
17 -- Settings in this section apply to the whole server and are the default settings
18 -- for any virtual hosts
20 -- This is a (by default, empty) list of accounts that are admins
21 -- for the server. Note that you must create the accounts separately
22 -- (see https://prosody.im/doc/creating_accounts for info)
23 -- Example: admins = { "user1@example.com", "user2@example.net" }
25 {% for item in prosody.admins %}
30 -- Enable use of libevent for better performance under high load
31 -- For more information see: https://prosody.im/doc/libevent
34 -- Prosody will always look in its source directory for modules, but
35 -- this option allows you to specify additional locations where Prosody
36 -- will look for modules first. For community modules, see https://modules.prosody.im/
37 plugin_paths = { "{{ prosody.paths.modules }}" }
39 -- This is the list of modules Prosody will load on startup.
40 -- It looks for mod_modulename.lua in the plugins folder, so make sure that exists too.
41 -- Documentation for bundled modules can be found at: https://prosody.im/doc/modules
45 "roster"; -- Allow users to have a roster. Recommended ;)
46 "saslauth"; -- Authentication for clients and servers. Recommended if you want to log in.
47 "tls"; -- Add support for secure TLS on c2s/s2s connections
48 "dialback"; -- s2s dialback support
49 "disco"; -- Service discovery
51 -- Not essential, but recommended
52 "carbons"; -- Keep multiple clients in sync
53 "pep"; -- Enables users to publish their mood, activity, playing music and more
54 "private"; -- Private XML storage (for room bookmarks, etc.)
55 "blocklist"; -- Allow users to block communications with other users
56 "vcard"; -- Allow users to set vCards
59 "version"; -- Replies to server version requests
60 "uptime"; -- Report how long server has been running
61 "time"; -- Let others know the time here on this server
62 "ping"; -- Replies to XMPP pings with pongs
63 "register"; -- Allow users to register on this server using a client and change passwords
64 "mam"; -- Store messages in an archive and allow users to access it
67 "admin_adhoc"; -- Allows administration via an XMPP client that supports ad-hoc commands
68 --"admin_telnet"; -- Opens telnet console interface on localhost port 5582
71 --"bosh"; -- Enable BOSH clients, aka "Jabber over HTTP"
72 --"websocket"; -- XMPP over WebSockets
73 --"http_files"; -- Serve static files from a directory over HTTP
75 -- Other specific functionality
76 --"limits"; -- Enable bandwidth limiting for XMPP connections
77 --"groups"; -- Shared roster support
78 --"server_contact_info"; -- Publish contact information for this service
79 "announce"; -- Send announcement to all online users
80 --"welcome"; -- Welcome users who register accounts
81 "watchregistrations"; -- Alert admins of registrations
82 --"motd"; -- Send a message to users when they log in
83 --"legacyauth"; -- Legacy authentication. Only used by some old clients and bots.
84 --"proxy65"; -- Enables a file transfer proxy service which clients behind NAT can use
87 "smacks"; -- XEP-0198: Stream Management
88 "csi_battery_saver"; -- XEP-0352: Client State Indication
89 "http_upload"; -- XEP-0363: HTTP File Upload
90 "register_web"; -- what it says on the tin
93 -- These modules are auto-loaded, but should you want
94 -- to disable them then uncomment them here:
96 -- "offline"; -- Store offline messages
97 -- "c2s"; -- Handle client connections
98 -- "s2s"; -- Handle server-to-server connections
99 -- "posix"; -- POSIX functionality, sends server to background, enables syslog, etc.
101 -- Disable account creation by default, for security
102 -- For more information see https://prosody.im/doc/creating_accounts
103 allow_registration = false
106 -- send the server to background.
111 -- Please, don't change this option since /var/run/prosody/
112 -- is one of the few directories Prosody is allowed to write to
114 pidfile = "/var/run/prosody/prosody.pid"
116 -- These are the SSL/TLS-related settings. If you don't want
117 -- to use SSL/TLS, you may comment or remove this
119 key = "/etc/ssl/private/letsencrypt/live.key";
120 certificate = "/etc/ssl/mycerts/letsencrypt/live.crt";
121 ciphers = "ALL:!EXPORT:!LOW:!MEDIUM:!aNULL:!3DES";
122 dhparam = "/etc/ssl/dh2048.pem";
124 -- support legacy clients
125 legacy_ssl_ports = { 5223 }
127 -- Force clients to use encrypted connections? This option will
128 -- prevent clients from authenticating unless they are using encryption.
130 c2s_require_encryption = true
132 -- Force servers to use encrypted connections? This option will
133 -- prevent servers from authenticating unless they are using encryption.
134 -- Note that this is different from authentication
136 s2s_require_encryption = true
138 -- Force certificate authentication for server-to-server connections?
139 -- This provides ideal security, but requires servers you communicate
140 -- with to support encryption AND present valid, trusted certificates.
141 -- NOTE: Your version of LuaSec must support certificate verification!
142 -- For more information see https://prosody.im/doc/s2s#security
144 s2s_secure_auth = false
146 -- Some servers have invalid or self-signed certificates. You can list
147 -- remote domains here that will not be required to authenticate using
148 -- certificates. They will be authenticated using DNS instead, even
149 -- when s2s_secure_auth is enabled.
150 -- However, if require_encryption is enabled, these hosts will still have
151 -- to use (unauthenticated) encryption.
153 s2s_insecure_domains = { "gmail.com"; "googlemail.com" }
155 -- Even if you leave s2s_secure_auth disabled, you can still require valid
156 -- certificates for some domains by specifying a list here.
158 -- s2s_secure_domains = { "jabber.org" }
160 -- Select the authentication backend to use. The 'internal' providers
161 -- use Prosody's configured data storage to store the authentication data.
162 -- To allow Prosody to offer secure authentication mechanisms to clients, the
163 -- default provider stores passwords in plaintext. If you do not trust your
164 -- server please see https://prosody.im/doc/modules/mod_auth_internal_hashed
165 -- for information about using the hashed backend.
167 authentication = "internal_hashed"
169 -- Select the storage backend to use. By default Prosody uses flat files
170 -- in its configured data directory, but it also supports more backends
171 -- through modules. An "sql" backend is included by default, but requires
172 -- additional dependencies. See https://prosody.im/doc/storage for more info.
174 --storage = "sql" -- Default is "internal" (Debian: "sql" requires one of the
175 -- lua-dbi-sqlite3, lua-dbi-mysql or lua-dbi-postgresql packages to work)
177 -- For the "sql" backend, you can uncomment *one* of the below to configure:
178 --sql = { driver = "SQLite3", database = "prosody.sqlite" } -- Default. 'database' is the filename.
179 --sql = { driver = "MySQL", database = "prosody", username = "prosody", password = "secret", host = "localhost" }
180 --sql = { driver = "PostgreSQL", database = "prosody", username = "prosody", password = "secret", host = "localhost" }
183 -- Archiving configuration
184 -- If mod_mam is enabled, Prosody will store a copy of every message. This
185 -- is used to synchronize conversations between multiple clients, even if
186 -- they are offline. This setting controls how long Prosody will keep
187 -- messages in the archive before removing them.
189 archive_expires_after = "2d" -- Remove archived messages after 2 days
191 -- You can also configure messages to be stored in-memory only. For more
192 -- archiving options, see https://prosody.im/doc/modules/mod_mam
195 -- Logging configuration
196 -- For advanced logging see https://prosody.im/doc/logging
199 -- Logs info and higher to /var/log
200 -- Logs errors to syslog also
202 -- Log files (change 'info' to 'debug' for debug logs):
203 warn = "/var/log/prosody/prosody.log";
204 error = "/var/log/prosody/prosody.err";
206 { levels = { "error" }; to = "syslog"; };
209 -- Registration notification
210 registration_watchers = admins
213 http_default_host = "{{ prosody.host }}"
215 http_upload_file_size_limit = 5 * 1024 * 1024
216 http_upload_expire_after = 60 * 60 * 24 * 7 -- a week in seconds
217 http_upload_quota = 50 * 1024 * 1024
219 ----------- Virtual hosts -----------
220 -- You need to add a VirtualHost entry for each domain you wish Prosody to serve.
221 -- Settings under each VirtualHost entry apply *only* to that host.
223 VirtualHost "{{ prosody.host }}"
225 ------ Components ------
226 -- You can specify components to add hosts that provide special services,
227 -- like multi-user conferences, and transports.
228 -- For more information on components, see https://prosody.im/doc/components
230 ---Set up a MUC (multi-user chat) room server on conference.example.com:
231 Component "conference.{{ prosody.host }}" "muc"
233 -- Set up a SOCKS5 bytestream proxy for server-proxied file transfers:
234 Component "proxy.{{ prosody.host }}" "proxy65"
236 ---Set up an external component (default component port is 5347)
238 -- External components allow adding various services, such as gateways/
239 -- transports to other networks like ICQ, MSN and Yahoo. For more info
240 -- see: https://prosody.im/doc/components#adding_an_external_component
242 --Component "gateway.example.com"
243 -- component_secret = "password"
245 ------ Additional config files ------
246 -- For organizational purposes you may prefer to add VirtualHost and
247 -- Component definitions in their own config files. This line includes
248 -- all config files in /etc/prosody/conf.d/
250 --Include "conf.d/*.cfg.lua"