prosody.cfg.lua.dist

Wed, 25 Nov 2009 23:45:45 +0000

author
Matthew Wild <mwild1@gmail.com>
date
Wed, 25 Nov 2009 23:45:45 +0000
changeset 2222
81b4e738e4d3
parent 2024
46a9c7c99476
child 2407
00121b728a02
child 2829
7f22d9c384e1
permissions
-rw-r--r--

util.serialization: Correctly serialize tables with 'false' as a key, fixes an issue with rosters not saving (thanks mathias, Tobias)

2024
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
1 -- Prosody Example Configuration File
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
2 --
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
3 -- If it wasn't already obvious, -- starts a comment, and all
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
4 -- text after it on a line is ignored by Prosody.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
5 --
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
6 -- The config is split into sections, a global section, and one
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
7 -- for each defined host that we serve. You can add as many host
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
8 -- sections as you like.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
9 --
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
10 -- Lists are written { "like", "this", "one" }
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
11 -- Lists can also be of { 1, 2, 3 } numbers, and other things.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
12 -- Either commas, or semi-colons; may be used
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
13 -- as seperators.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
14 --
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
15 -- A table is a list of values, except each value has a name. An
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
16 -- example table would be:
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
17 --
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
18 -- ssl = { key = "keyfile.key", certificate = "certificate.cert" }
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
19 --
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
20 -- Whitespace (that is tabs, spaces, line breaks) is mostly insignificant, so
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
21 -- can
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
22 -- be placed anywhere that you deem fitting.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
23 --
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
24 -- Tip: You can check that the syntax of this file is correct when you have finished
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
25 -- by running: luac -p prosody.cfg.lua
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
26 -- If there are any errors, it will let you know what and where they are, otherwise it
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
27 -- will keep quiet.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
28 --
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
29 -- The only thing left to do is rename this file to remove the .dist ending, and fill in the
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
30 -- blanks. Good luck, and happy Jabbering!
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
31
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
32 -- Server-wide settings go in this section
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
33 Host "*"
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
34
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
35 -- This is a (by default, empty) list of accounts that are admins
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
36 -- for the server. Note that you must create the accounts separately
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
37 -- (see http://prosody.im/doc/creating_accounts for info)
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
38 -- Example: admins = { "user1@example.com", "user2@example.net" }
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
39 admins = { }
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
40
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
41 -- This is the list of modules Prosody will load on startup.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
42 -- It looks for mod_modulename.lua in the plugins folder, so make sure that exists too.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
43 modules_enabled = {
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
44 -- Generally required
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
45 "roster"; -- Allow users to have a roster. Recommended ;)
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
46 "saslauth"; -- Authentication for clients and servers. Recommended if you want to log in.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
47 "tls"; -- Add support for secure TLS on c2s/s2s connections
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
48 "dialback"; -- s2s dialback support
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
49 "disco"; -- Service discovery
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
50
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
51 -- Not essential, but recommended
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
52 "private"; -- Private XML storage (for room bookmarks, etc.)
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
53 "vcard"; -- Allow users to set vCards
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
54
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
55 -- Nice to have
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
56 "legacyauth"; -- Legacy authentication. Only used by some old clients and bots.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
57 "version"; -- Replies to server version requests
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
58 "uptime"; -- Report how long server has been running
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
59 "time"; -- Let others know the time here on this server
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
60 "ping"; -- Replies to XMPP pings with pongs
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
61 "pep"; -- Enables users to publish their mood, activity, playing music and more
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
62 "register"; -- Allow users to register on this server using a client and change passwords
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
63
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
64 -- Other specific functionality
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
65 --"posix"; -- POSIX functionality, sends server to background, enables syslog, etc.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
66 --"console"; -- telnet to port 5582 (needs console_enabled = true)
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
67 --"bosh"; -- Enable BOSH clients, aka "Jabber over HTTP"
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
68 --"httpserver"; -- Serve static files from a directory over HTTP
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
69 };
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
70
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
71 -- These modules are auto-loaded, should you
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
72 -- for (for some mad reason) want to disable
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
73 -- them then uncomment them below
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
74 modules_disabled = {
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
75 -- "presence";
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
76 -- "message";
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
77 -- "iq";
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
78 };
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
79
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
80 -- Disable account creation by default, for security
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
81 -- For more information see http://prosody.im/doc/creating_accounts
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
82 allow_registration = false;
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
83
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
84 -- These are the SSL/TLS-related settings. If you don't want
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
85 -- to use SSL/TLS, you may comment or remove this
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
86 ssl = {
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
87 key = "certs/localhost.key";
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
88 certificate = "certs/localhost.cert";
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
89 }
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
90
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
91 -- This allows clients to connect to localhost. No harm in it.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
92 Host "localhost"
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
93
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
94 -- Section for example.com
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
95 -- (replace example.com with your domain name)
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
96 Host "example.com"
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
97
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
98 enabled = false -- This will disable the host, preserving the config, but denying connections
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
99
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
100 -- Assign this host a certificate for TLS, otherwise it would use the one
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
101 -- set in the global section (if any).
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
102 -- Note that old-style SSL on port 5223 only supports one certificate, and will always
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
103 -- use the global one.
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
104 ssl = {
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
105 key = "certs/example.com.key";
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
106 certificate = "certs/example.com.crt";
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
107 }
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
108
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
109 -- Set up a MUC (multi-user chat) room server on conference.example.com:
46a9c7c99476 prosody.cfg.lua.dist: Convert to unix line endings from DOS
Matthew Wild <mwild1@gmail.com>
parents: 1809
diff changeset
110 Component "conference.example.com" "muc"

mercurial