Cant get running jitsi on local ip in docker (new to docker)

I meant, docker was running fine with fake domain=“meet.jitsi” but after that I stopped all containers,removed them and deleted config folder and then again run with changing the “meet.jitsi” to “192.168.0.149” in xmpp parts of “.env” file. though I didnt make change in “docker-compose.yml”(I didnt understand the linking of meet.jitsi network in this file,I just thought it was only in .env file) file it was running fine. is this should be ok?

No, that probably isn’t ok. You also need to check the aliases in docker-compose. Really, don’t do it. It’s only there so people can change it if they run the containers separately, like in k8s or something elsse. The compose setup works best as is.

I have done as u said and it is working fine now with authentication and etherpad.

Now I want to use "muc_size" module to monitor my server. I know it needs prosody 0.11 or higher.. how can I know which versions of prosody/jvb/jicofo are running in docker? if it is 0.11 or higher what should I do next?

as far as I understood,by running docker-compose.yml it indicate and configure the services and then the docker files in the service folder get to running and save a compiled configuration of the instructions in config folder which is also used for later running.
I tried to check prosody version in dockerfile but couldn’t. I even tried to add “muc_size” module in modules enabled area of prosody/rootfs/defaults/conf.d/jitsi-meet.cfg.lua but found out no change in actual “config folder” -> “prosody”. then manually added the module to virtual host “meet.jitsi” in config/prosody/conf.d. now should I reload or something to get the effect?
I saw there are already some modules enabled like “bosh”,“pubsub”,“ping” and plugin_paths = { “/prosody-plugins/”, “/prosody-plugins-custom” } but I couldn’t find the prosody-plugins folder where these modules are already added. how to find the folder and how can add “muc_size” module if it isn’t there… ? is this even possible to run query in server while running in docker ?

Thanx in advance @saghul :heart:

You’d need to modify the base prosody image. It may not be very straightforward if you are new to Docker. Look at how other plugins are enabled. I’d be ok with having it on the base install, behind a flag.

Thanx for the reply.
I found out that the prosody version is 0.11.2 so this mean I can use muc_size module … here what I did and failed:

  1. clone the git repo and docker compose run.
  2. but after making changes (like enabling a module) to that git repo doesnt reflect even in the {config} folder and ofcourse not in the server.
  3. Then I tried to make changes in the {config} folder so while restarting the container will find the changes in image.but maybe not… bcz after restarting I went inside prosody container and found out there is no muc_size in usr/lib/prosody/modules though I enabled it in {configure} folder.
  4. I even tried manually to copy the muc_size module in the prosody containers in run time but it didnt work… the same output:
    " 404 Not Found
    Whatever you were looking for is not here. Keep looking." in the “...:5280” - the url of docker prosody container(found out by inspecting container) while tried to access.

actually what should I do? how can I rebuild the image with new file changed(where should be changed? git repo or {config} folder?) and run the container. I tried using --build but didnt work. why the modeule is not loaded though I enabled it both in git repo and {config} folder? how should I enable the module and make it work? u can suggest me any docker tutorial related to these issues. Thanx in advance :heart: @saghul

You need to rebuild the images after making changes to the rootfs files. You can rebuild them by running make

yeah I was able to do it bt I am facing hard times adding mod_muc_size module via mounting the volume prosody_plugins_custom … I found a issue where this was said to do… my ques is… after running the container with built images (where I already enabled the muc_size module in prosody.cfg.lua and meet.jitsi) how can I actually add the module to the volume? can I just manually add the file to volume while the container is still running and it will be updated automatically? Thanx

You can add it by using the ADD directive in the Dockerfile.

but thing seemed complicated here :


:slight_smile: I am still facing problem :broken_heart:
u r saying I can just add :

ADD /prosody_plugins_custom/mod_muc_size.lua 

in the prsody docker file and my work is done?

Yes, you need to add it. But note that it needs to exist in the source directory or URL.

so the thing is…
first, I enabled muc_size module in git repo and then I rebuild images after deleting the {config} folder

then, “add /prosody_plugins_custom/mod_muc_size.lua” dockerfile and put the lua file in git_repo//prosody_plugins_custom/mod_muc_size.lua ? then docker compose run?

Wait, isn’t the file already present in the base image? Without any changes, that is. If you enter the container, isn’t it in /prosody-plugins ?

may b not… after running when I go into prosody container and there in usr/lib/prosody/modules there is no mod_muc_size.lua

can u plz tell me from start after up&running of normal docker jitsi server … what should I do to enable muc_size module to run a query … bcz I just got lost in that :sob: :sob:

Let’s take a step back. Without any changes the file is already there:

saghul@meet:~/src/docker-jitsi-meet$ docker-compose exec prosody /bin/bash
root@3a1fb89fe55a:/# ls -l /prosody-plugins
total 116
-rw-r--r-- 1 prosody root  1885 Dec 28  2018 ext_events.lib.lua
-rw-r--r-- 1 prosody root  2543 Jan  8 17:19 mod_auth_token.lua
-rw-r--r-- 1 prosody root  1075 Jun 15  2018 mod_filter_iq_jibri.lua
-rw-r--r-- 1 prosody root  7104 Sep 30 17:57 mod_filter_iq_rayo.lua
-rw-r--r-- 1 prosody root   462 Feb 26  2017 mod_muc_allowners.lua
-rw-r--r-- 1 prosody root  4067 Jul 16  2018 mod_muc_call.lua
-rw-r--r-- 1 prosody root  6316 Oct 24 13:45 mod_muc_domain_mapper.lua
-rw-r--r-- 1 prosody root  2271 Nov  3  2018 mod_muc_max_occupants.lua
-rw-r--r-- 1 prosody root 10584 May 16  2019 mod_muc_poltergeist.lua
-rw-r--r-- 1 prosody root  5802 Jul  9  2018 mod_muc_size.lua
-rw-r--r-- 1 prosody root   592 Jul 17  2017 mod_poltergeist_component.lua
-rw-r--r-- 1 prosody root   728 Mar 23  2018 mod_presence_identity.lua
-rw-r--r-- 1 prosody root   306 Dec 28  2018 mod_speakerstats.lua
-rw-r--r-- 1 prosody root  7345 Nov 13 16:40 mod_speakerstats_component.lua
-rw-r--r-- 1 prosody root  2305 Jun 26  2017 mod_token_verification.lua
-rw-r--r-- 1 prosody root  1065 Feb 26  2017 muc_owner_allow_kick.patch
-rw-r--r-- 1 prosody root 13526 Jun 29  2018 poltergeist.lib.lua
drwxr-xr-x 1 prosody root  4096 Jun  6  2019 token
-rw-r--r-- 1 prosody root  7128 Jul 17  2018 util.lib.lua
root@3a1fb89fe55a:/#

So all you need to do is change the config in the rootfs, build the image with make and recreate the containers.

Sorry for late reply . But after recreating the container with newly built images where muc_size modules are enabled … there isn’t muc_size module in prosody - usr/lib/prosody/modules . isn’t this the path where all loaded modules are present?
so should this be the thing :

  1. config the prosody part. enable muc_size module in prosody.cfg.lua and in jitsi-meet.cfg.lua . which I did before too. build image and run the container. how can I be sure the module is loaded ? shouldn’t it be in usr/lib/prosody/modules ?
    when building the image in prosody folder I used “sudo docker build . -t jitsi/prosody” command and this is the output :
Sending build context to Docker daemon  27.65kB
Step 1/8 : ARG JITSI_REPO=jitsi
Step 2/8 : FROM ${JITSI_REPO}/base
 ---> 3e2e730818bd
Step 3/8 : RUN     apt-dpkg-wrap apt-get update     && apt-dpkg-wrap apt-get install -t stretch-backports -y       prosody       liblua5.2-dev       sasl2-bin       libsasl2-modules-ldap       libsasl2-dev       libssl1.0-dev       lua-basexx       lua-ldap       luarocks       git       gcc       patch     && luarocks install cyrussasl 1.1.0-1     && luarocks install lua-cjson 2.1.0-1     && luarocks install luajwtjitsi 1.3-7     && luarocks install net-url 0.9-1     && apt-dpkg-wrap apt-get remove -t stretch-backports -y       git       gcc       luarocks       libsasl2-dev       libssl1.0-dev       liblua5.2-dev     && apt-cleanup     && rm -rf /etc/prosody /var/cache/apt
 ---> Using cache
 ---> e7f91de68bf2
Step 4/8 : RUN     apt-dpkg-wrap apt-get update     && apt-dpkg-wrap apt-get -d install -y jitsi-meet-tokens     && dpkg -x /var/cache/apt/archives/jitsi-meet-tokens*.deb /tmp     && mv /tmp/usr/share/jitsi-meet/prosody-plugins /prosody-plugins     && apt-cleanup     && rm -rf /tmp/usr /var/cache/apt
 ---> Using cache
 ---> c825f7e6fa74
Step 5/8 : RUN     sed -i s/hook/hook_global/g /prosody-plugins/mod_auth_token.lua     && patch -d /usr/lib/prosody/modules/muc -p0 < /prosody-plugins/muc_owner_allow_kick.patch
 ---> Using cache
 ---> fc0ce2982731
Step 6/8 : COPY rootfs/ /
 ---> Using cache
 ---> 9ce318ddd1f3
Step 7/8 : EXPOSE 5222 5269 5347 5280
 ---> Using cache
 ---> 7523b8d68ac0
Step 8/8 : VOLUME ["/config", "/prosody-plugins-custom"]
 ---> Using cache
 ---> bbd837f7588d
Successfully built bbd837f7588d
Successfully tagged jitsi/prosody:latest

not sure whether the muc_size module is loaded or not for cache issue. may be it is using the I ran the docker compose command. this is what I saw when container was running :

prosody_1  | recorder.meet.jitsi:muc_size  error	'app_id' must not be empty
prosody_1  | portmanager                   info	Activated service 'http' on [*]:5280, [::]:5280
prosody_1  | portmanager                   info	Activated service 'https' on no ports
prosody_1  | portmanager                   info	Activated service 'component' on [*]:5347
prosody_1  | auth.meet.jitsi:muc_size      error	'app_id' must not be empty
prosody_1  | meet.jitsi:muc_size           error	'app_id' must not be empty
  1. now my docker is up. I inspected the container for ip address and that was 172.18.0.3 (prosody) then for http://172.18.0.3:5280/ it was 404 error,saying that what I am looking is behind me… though http://172.18.0.3:5280/http-bind worked… http://172.18.0.3:5280/get-info-rooms or other muc_size module command didnt work at all (404 error)

my first concern is how can I be sure that muc_size module is loaded? then was this the right way to find prosody ip address then querying? should I also add some nginx configuration too for getting the query result?
plz help … thanx in advance @saghul :heart:

Yes and no. Look at my paste above. They are in a different location, but that’s ok, because we specify that module path anyway.

You should get an error when starting prosody.

No, it’s fine for it to be where it is.

You need to fix this error.

You could add a proxy URL to avoid having to type the port.

so as I wasnt facing prosody problems then muc size module is working I assume… but why I see 404 error in http://192.168.0.149:5280/get-info-rooms where http://192.168.0.149:5280/http-bind is working?
is this for app_id problem? if so what should I do?
what is the right way to add proxy url in web container…? as I tried and failed ,here is my config for get-info-rooms in meet.conf:

server_name _;

client_max_body_size 0;

root /usr/share/jitsi-meet;
index index.html
error_page 404 /static/404.html;

location ~ ^/([a-zA-Z0-9=\?]+)$ {
    rewrite ^/(.*)$ / break;
}

location /config.js {
    alias /config/config.js;
}

location /interface_config.js {
    alias /config/interface_config.js;
}

location /external_api.js {
    alias /usr/share/jitsi-meet/libs/external_api.min.js;
}

location / {
    ssi on;
}

# BOSH
location /http-bind {
    proxy_pass {{ .Env.XMPP_BOSH_URL_BASE }}/http-bind;
    proxy_set_header X-Forwarded-For $remote_addr;
    proxy_set_header Host {{ .Env.XMPP_DOMAIN }};
}

# get-info-rooms
location /get-info-rooms {
    proxy_pass http://192.168.12.3:5280/get-info-rooms;
    proxy_set_header X-Forwarded-For $remote_addr;
    proxy_set_header Host {{ .Env.XMPP_DOMAIN }};
}

{{ if .Env.ETHERPAD_URL_BASE }}
# Etherpad-lite
location /etherpad/ {
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection 'upgrade';
    proxy_set_header Host $host;
    proxy_cache_bypass $http_upgrade;

    proxy_pass {{ .Env.ETHERPAD_URL_BASE }}/;
    proxy_set_header X-Forwarded-For $remote_addr;
    proxy_buffering off;
    proxy_set_header Host {{ .Env.XMPP_DOMAIN }};
}
{{ end }}

here the url was the ip of prosody docker container… but the problem is I cant know the ip until it is running and it is changing in every run
thanx in advance :heart:

Use a similar construct for the room size plugin. As for the app ID error, I don’t know really. @damencho do you know if anything epecial needs to be configured for that module?

That module requires a token to be passed to access it, so you don’t reveal sensitive information to the public.


It complains that app_id is not defined in order to verify the token.
You can set enable_roomsize_token_verification in prosody config to false, which is the default value and that verification will be disabled.