nixos/movim: rename to prosody-nginx to be clearer
This commit is contained in:
parent
0d9a758f73
commit
d00a5703d9
@ -11,5 +11,5 @@ let
|
||||
];
|
||||
in
|
||||
{
|
||||
standard = handleTestOn supportedSystems ./standard.nix { inherit system; };
|
||||
prosody-nginx = handleTestOn supportedSystems ./prosody-nginx.nix { inherit system; };
|
||||
}
|
||||
|
||||
@ -7,17 +7,17 @@ import ../../make-test-python.nix (
|
||||
info = "No ToS in tests";
|
||||
description = "NixOS testing server";
|
||||
};
|
||||
xmpp = {
|
||||
domain = "xmpp.local";
|
||||
prosody = {
|
||||
domain = "prosody.local";
|
||||
admin = rec {
|
||||
JID = "${username}@${xmpp.domain}";
|
||||
JID = "${username}@${prosody.domain}";
|
||||
username = "romeo";
|
||||
password = "juliet";
|
||||
};
|
||||
};
|
||||
in
|
||||
{
|
||||
name = "movim-standard";
|
||||
name = "movim-prosody-nginx";
|
||||
|
||||
meta = {
|
||||
maintainers = with pkgs.lib.maintainers; [ toastal ];
|
||||
@ -33,7 +33,7 @@ import ../../make-test-python.nix (
|
||||
verbose = true;
|
||||
podConfig = {
|
||||
inherit (movim) description info;
|
||||
xmppdomain = xmpp.domain;
|
||||
xmppdomain = prosody.domain;
|
||||
};
|
||||
nginx = { };
|
||||
};
|
||||
@ -43,20 +43,20 @@ import ../../make-test-python.nix (
|
||||
xmppComplianceSuite = false;
|
||||
disco_items = [
|
||||
{
|
||||
url = "upload.${xmpp.domain}";
|
||||
url = "upload.${prosody.domain}";
|
||||
description = "File Uploads";
|
||||
}
|
||||
];
|
||||
virtualHosts."${xmpp.domain}" = {
|
||||
inherit (xmpp) domain;
|
||||
virtualHosts."${prosody.domain}" = {
|
||||
inherit (prosody) domain;
|
||||
enabled = true;
|
||||
extraConfig = ''
|
||||
Component "pubsub.${xmpp.domain}" "pubsub"
|
||||
Component "pubsub.${prosody.domain}" "pubsub"
|
||||
pubsub_max_items = 10000
|
||||
expose_publisher = true
|
||||
|
||||
Component "upload.${xmpp.domain}" "http_file_share"
|
||||
http_external_url = "http://upload.${xmpp.domain}"
|
||||
Component "upload.${prosody.domain}" "http_file_share"
|
||||
http_external_url = "http://upload.${prosody.domain}"
|
||||
http_file_share_expires_after = 300 * 24 * 60 * 60
|
||||
http_file_share_size_limit = 1024 * 1024 * 1024
|
||||
http_file_share_daily_quota = 4 * 1024 * 1024 * 1024
|
||||
@ -73,7 +73,7 @@ import ../../make-test-python.nix (
|
||||
|
||||
networking.extraHosts = ''
|
||||
127.0.0.1 ${movim.domain}
|
||||
127.0.0.1 ${xmpp.domain}
|
||||
127.0.0.1 ${prosody.domain}
|
||||
'';
|
||||
};
|
||||
};
|
||||
@ -86,7 +86,7 @@ import ../../make-test-python.nix (
|
||||
|
||||
server.wait_for_unit("prosody.service")
|
||||
server.succeed('prosodyctl status | grep "Prosody is running"')
|
||||
server.succeed("prosodyctl register ${xmpp.admin.username} ${xmpp.domain} ${xmpp.admin.password}")
|
||||
server.succeed("prosodyctl register ${prosody.admin.username} ${prosody.domain} ${prosody.admin.password}")
|
||||
|
||||
server.wait_for_unit("movim.service")
|
||||
|
||||
@ -102,7 +102,7 @@ import ../../make-test-python.nix (
|
||||
assert "${movim.info}" in login_html
|
||||
|
||||
# Test authentication POST
|
||||
server.succeed("curl --fail-with-body -b /tmp/cookies -X POST --data-urlencode 'username=${xmpp.admin.JID}' --data-urlencode 'password=${xmpp.admin.password}' http://${movim.domain}/login")
|
||||
server.succeed("curl --fail-with-body -b /tmp/cookies -X POST --data-urlencode 'username=${prosody.admin.JID}' --data-urlencode 'password=${prosody.admin.password}' http://${movim.domain}/login")
|
||||
|
||||
server.succeed("curl -L --fail-with-body --max-redirs 1 -b /tmp/cookies http://${movim.domain}/chat")
|
||||
'';
|
||||
Loading…
x
Reference in New Issue
Block a user