Software / code / prosody
Comparison
prosodyctl @ 7359:a5a080c12c96
Update every link to the documentation to use HTTPS
| author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
|---|---|
| date | Sat, 16 Apr 2016 21:08:05 +0100 |
| parent | 7313:316ca5c15255 |
| child | 7447:843fe134453e |
comparison
equal
deleted
inserted
replaced
| 7358:d0390bc9c5d1 | 7359:a5a080c12c96 |
|---|---|
| 101 print("Prosody was unable to find the configuration file."); | 101 print("Prosody was unable to find the configuration file."); |
| 102 print("We looked for: "..(CFG_CONFIGDIR or ".").."/prosody.cfg.lua"); | 102 print("We looked for: "..(CFG_CONFIGDIR or ".").."/prosody.cfg.lua"); |
| 103 print("A sample config file is included in the Prosody download called prosody.cfg.lua.dist"); | 103 print("A sample config file is included in the Prosody download called prosody.cfg.lua.dist"); |
| 104 print("Copy or rename it to prosody.cfg.lua and edit as necessary."); | 104 print("Copy or rename it to prosody.cfg.lua and edit as necessary."); |
| 105 end | 105 end |
| 106 print("More help on configuring Prosody can be found at http://prosody.im/doc/configure"); | 106 print("More help on configuring Prosody can be found at https://prosody.im/doc/configure"); |
| 107 print("Good luck!"); | 107 print("Good luck!"); |
| 108 print("**************************"); | 108 print("**************************"); |
| 109 print(""); | 109 print(""); |
| 110 os.exit(1); | 110 os.exit(1); |
| 111 end | 111 end |
| 166 pposix.umask(config.get("*", "umask") or "027"); | 166 pposix.umask(config.get("*", "umask") or "027"); |
| 167 pposix.setenv("HOME", data_path); | 167 pposix.setenv("HOME", data_path); |
| 168 pposix.setenv("PROSODY_CONFIG", ENV_CONFIG); | 168 pposix.setenv("PROSODY_CONFIG", ENV_CONFIG); |
| 169 else | 169 else |
| 170 print("Error: Unable to load pposix module. Check that Prosody is installed correctly.") | 170 print("Error: Unable to load pposix module. Check that Prosody is installed correctly.") |
| 171 print("For more help send the below error to us through http://prosody.im/discuss"); | 171 print("For more help send the below error to us through https://prosody.im/discuss"); |
| 172 print(tostring(pposix)) | 172 print(tostring(pposix)) |
| 173 os.exit(1); | 173 os.exit(1); |
| 174 end | 174 end |
| 175 | 175 |
| 176 local function test_writeable(filename) | 176 local function test_writeable(filename) |
| 217 ["invalid-hostname"] = "The given hostname is invalid"; | 217 ["invalid-hostname"] = "The given hostname is invalid"; |
| 218 ["no-password"] = "No password was supplied"; | 218 ["no-password"] = "No password was supplied"; |
| 219 ["no-such-user"] = "The given user does not exist on the server"; | 219 ["no-such-user"] = "The given user does not exist on the server"; |
| 220 ["no-such-host"] = "The given hostname does not exist in the config"; | 220 ["no-such-host"] = "The given hostname does not exist in the config"; |
| 221 ["unable-to-save-data"] = "Unable to store, perhaps you don't have permission?"; | 221 ["unable-to-save-data"] = "Unable to store, perhaps you don't have permission?"; |
| 222 ["no-pidfile"] = "There is no 'pidfile' option in the configuration file, see http://prosody.im/doc/prosodyctl#pidfile for help"; | 222 ["no-pidfile"] = "There is no 'pidfile' option in the configuration file, see https://prosody.im/doc/prosodyctl#pidfile for help"; |
| 223 ["invalid-pidfile"] = "The 'pidfile' option in the configuration file is not a string, see http://prosody.im/doc/prosodyctl#pidfile for help"; | 223 ["invalid-pidfile"] = "The 'pidfile' option in the configuration file is not a string, see https://prosody.im/doc/prosodyctl#pidfile for help"; |
| 224 ["no-posix"] = "The mod_posix module is not enabled in the Prosody config file, see http://prosody.im/doc/prosodyctl for more info"; | 224 ["no-posix"] = "The mod_posix module is not enabled in the Prosody config file, see https://prosody.im/doc/prosodyctl for more info"; |
| 225 ["no-such-method"] = "This module has no commands"; | 225 ["no-such-method"] = "This module has no commands"; |
| 226 ["not-running"] = "Prosody is not running"; | 226 ["not-running"] = "Prosody is not running"; |
| 227 }, { __index = function (t,k) return "Error: "..(tostring(k):gsub("%-", " "):gsub("^.", string.upper)); end }); | 227 }, { __index = function (t,k) return "Error: "..(tostring(k):gsub("%-", " "):gsub("^.", string.upper)); end }); |
| 228 | 228 |
| 229 hosts = prosody.hosts; | 229 hosts = prosody.hosts; |
| 880 -- Check that we have any global options (caused by putting a host at the top) | 880 -- Check that we have any global options (caused by putting a host at the top) |
| 881 if it.count(it.filter("log", pairs(config["*"]))) == 0 then | 881 if it.count(it.filter("log", pairs(config["*"]))) == 0 then |
| 882 ok = false; | 882 ok = false; |
| 883 print(""); | 883 print(""); |
| 884 print(" No global options defined. Perhaps you have put a host definition at the top") | 884 print(" No global options defined. Perhaps you have put a host definition at the top") |
| 885 print(" of the config file? They should be at the bottom, see http://prosody.im/doc/configure#overview"); | 885 print(" of the config file? They should be at the bottom, see https://prosody.im/doc/configure#overview"); |
| 886 end | 886 end |
| 887 if it.count(enabled_hosts()) == 0 then | 887 if it.count(enabled_hosts()) == 0 then |
| 888 ok = false; | 888 ok = false; |
| 889 print(""); | 889 print(""); |
| 890 if it.count(it.filter("*", pairs(config))) == 0 then | 890 if it.count(it.filter("*", pairs(config))) == 0 then |
| 932 ok = false; | 932 ok = false; |
| 933 print(""); | 933 print(""); |
| 934 local n = it.count(misplaced_options); | 934 local n = it.count(misplaced_options); |
| 935 print(" You have "..n.." option"..(n>1 and "s " or " ").."set under "..host.." that should be"); | 935 print(" You have "..n.." option"..(n>1 and "s " or " ").."set under "..host.." that should be"); |
| 936 print(" in the global section of the config file, above any VirtualHost or Component definitions,") | 936 print(" in the global section of the config file, above any VirtualHost or Component definitions,") |
| 937 print(" see http://prosody.im/doc/configure#overview for more information.") | 937 print(" see https://prosody.im/doc/configure#overview for more information.") |
| 938 print(""); | 938 print(""); |
| 939 print(" You need to move the following option"..(n>1 and "s" or "")..": "..table.concat(it.to_array(misplaced_options), ", ")); | 939 print(" You need to move the following option"..(n>1 and "s" or "")..": "..table.concat(it.to_array(misplaced_options), ", ")); |
| 940 end | 940 end |
| 941 local subdomain = host:match("^[^.]+"); | 941 local subdomain = host:match("^[^.]+"); |
| 942 if not(host_options:contains("component_module")) and (subdomain == "jabber" or subdomain == "xmpp" | 942 if not(host_options:contains("component_module")) and (subdomain == "jabber" or subdomain == "xmpp" |
| 943 or subdomain == "chat" or subdomain == "im") then | 943 or subdomain == "chat" or subdomain == "im") then |
| 944 print(""); | 944 print(""); |
| 945 print(" Suggestion: If "..host.. " is a new host with no real users yet, consider renaming it now to"); | 945 print(" Suggestion: If "..host.. " is a new host with no real users yet, consider renaming it now to"); |
| 946 print(" "..host:gsub("^[^.]+%.", "")..". You can use SRV records to redirect XMPP clients and servers to "..host.."."); | 946 print(" "..host:gsub("^[^.]+%.", "")..". You can use SRV records to redirect XMPP clients and servers to "..host.."."); |
| 947 print(" For more information see: http://prosody.im/doc/dns"); | 947 print(" For more information see: https://prosody.im/doc/dns"); |
| 948 end | 948 end |
| 949 end | 949 end |
| 950 local all_modules = set.new(config["*"].modules_enabled); | 950 local all_modules = set.new(config["*"].modules_enabled); |
| 951 local all_options = set.new(it.to_array(it.keys(config["*"]))); | 951 local all_options = set.new(it.to_array(it.keys(config["*"]))); |
| 952 for host in enabled_hosts() do | 952 for host in enabled_hosts() do |
| 1180 if #bad_protos > 0 then | 1180 if #bad_protos > 0 then |
| 1181 print(" Host "..host.." does not seem to resolve to this server ("..table.concat(bad_protos, "/")..")"); | 1181 print(" Host "..host.." does not seem to resolve to this server ("..table.concat(bad_protos, "/")..")"); |
| 1182 end | 1182 end |
| 1183 if host_ok_v6 and not v6_supported then | 1183 if host_ok_v6 and not v6_supported then |
| 1184 print(" Host "..host.." has AAAA records, but your version of LuaSocket does not support IPv6."); | 1184 print(" Host "..host.." has AAAA records, but your version of LuaSocket does not support IPv6."); |
| 1185 print(" Please see http://prosody.im/doc/ipv6 for more information."); | 1185 print(" Please see https://prosody.im/doc/ipv6 for more information."); |
| 1186 end | 1186 end |
| 1187 end | 1187 end |
| 1188 if not all_targets_ok then | 1188 if not all_targets_ok then |
| 1189 print(" "..(some_targets_ok and "Only some" or "No").." targets for "..host.." appear to resolve to this server."); | 1189 print(" "..(some_targets_ok and "Only some" or "No").." targets for "..host.." appear to resolve to this server."); |
| 1190 if is_component then | 1190 if is_component then |
| 1194 end | 1194 end |
| 1195 print(""); | 1195 print(""); |
| 1196 end | 1196 end |
| 1197 if not problem_hosts:empty() then | 1197 if not problem_hosts:empty() then |
| 1198 print(""); | 1198 print(""); |
| 1199 print("For more information about DNS configuration please see http://prosody.im/doc/dns"); | 1199 print("For more information about DNS configuration please see https://prosody.im/doc/dns"); |
| 1200 print(""); | 1200 print(""); |
| 1201 ok = false; | 1201 ok = false; |
| 1202 end | 1202 end |
| 1203 end | 1203 end |
| 1204 if not what or what == "certs" then | 1204 if not what or what == "certs" then |
| 1273 end | 1273 end |
| 1274 end | 1274 end |
| 1275 end | 1275 end |
| 1276 if cert_ok == false then | 1276 if cert_ok == false then |
| 1277 print("") | 1277 print("") |
| 1278 print("For more information about certificates please see http://prosody.im/doc/certificates"); | 1278 print("For more information about certificates please see https://prosody.im/doc/certificates"); |
| 1279 ok = false | 1279 ok = false |
| 1280 end | 1280 end |
| 1281 end | 1281 end |
| 1282 print("") | 1282 print("") |
| 1283 end | 1283 end |