# Mumble (Docker) An alternate install guide for Mumble using Docker, better suited to an Alliance Auth Docker install Mumble is a free voice chat server. While not as flashy as TeamSpeak, it has all the functionality and is easier to customize. And is better. I may be slightly biased. ## Installing Dependencies Due to some complications with Zeroc-Ice, it is not installed in the standard docker container. This is hoped to be resolved upstream in a later version of Zeroc-Ice. You will need to follow [Using a custom docker image](../../installation-containerized/docker.md#using-a-custom-docker-image) instructions and include `zeroc-ice` in your `conf/requirements.txt` ## Configuring Auth In your auth project's settings file (`myauth/settings/local.py`), do the following: - Add `'allianceauth.services.modules.mumble',` to your `INSTALLED_APPS` list - Set `MUMBLE_URL` to the public address of your mumble server. Do not include any leading `http://` or `mumble://`. Example config: ```python # Installed apps INSTALLED_APPS += [ # ... 'allianceauth.services.modules.mumble' # ... ] # Mumble Configuration MUMBLE_URL = "mumble.example.com" ``` Add the following lines to your `.env` file ```bash # Mumble MUMBLE_SUPERUSER_PASSWORD = superuser_password MUMBLE_ICESECRETWRITE = icesecretwrite MUMBLE_SERVERPASSWORD = serverpassword ``` Finally, restart your stack and run migrations ```shell docker compose --env-file=.env up -d docker compose exec allianceauth_gunicorn bash auth migrate ``` ## Configuring Authenticator The Authenticator is configured via Django Admin, visit `/admin/mumble/mumbleserverserver/` to add a virtual server. Ensure you enter the Ice Secret here, that you set earlier as `icesecretwrite` in `murmur.ini` and select the Slice that matches your Mumble server version. Host and Endpoint IP may need to be changed if you are running a remote Mumble server ## Docker Installations ### Installing Mumble and Authenticator Add the following to your `docker-compose.yml` under the `services:` section ```docker mumble-server: image: mumblevoip/mumble-server:latest restart: always environment: - MUMBLE_SUPERUSER_PASSWORD=${MUMBLE_SUPERUSER_PASSWORD} - MUMBLE_CONFIG_ice="tcp -h 127.0.0.1 -p 6502" - MUMBLE_CONFIG_icesecretwrite=${MUMBLE_ICESECRETWRITE} - MUMBLE_CONFIG_serverpassword=${MUMBLE_SERVERPASSWORD} - MUMBLE_CONFIG_opusthreshold=0 - MUMBLE_CONFIG_suggestPushToTalk=true - MUMBLE_CONFIG_suggestVersion=1.4.0 ports: - 64738:64738 - 64738:64738/udp logging: driver: "json-file" options: max-size: "10Mb" max-file: "5" allianceauth_mumble_authenticator: container_name: allianceauth_mumble_authenticator <<: [*allianceauth-base] entrypoint: [ "python", "manage.py", "mumble_authenticator", "--server_id=1" ] ``` ## Permissions To use this service, users will require some of the following. ```{eval-rst} +---------------------------------------+------------------+--------------------------------------------------------------------------+ | Permission | Admin Site | Auth Site | +=======================================+==================+==========================================================================+ | mumble.access_mumble | None | Can Access the Mumble Service | +---------------------------------------+------------------+--------------------------------------------------------------------------+ ``` ## ACL configuration On a freshly installed mumble server only your superuser has the right to configure ACLs and create channels. The credentials for logging in with your superuser are: - user: `SuperUser` - password: *what you defined when configuring your mumble server* ## Enabling Templinks Since AA v5 Templinks are now built-in and require no additional community apps, but they do require a setting to expose the Templink page publicly, as this feature is not enabled by default. In `local.py` you need to add `mumble` to `APPS_WITH_PUBLIC_VIEWS`. This list might already contain additional apps so add as needed. ```python APPS_WITH_PUBLIC_VIEWS = [ "mumble", ] ``` Restart Auth via Docker Compose for the changes to take effect ## Optimizing a Mumble Server The needs and available resources will vary between Alliance Auth installations. Consider yours when applying these settings. ### Bandwidth This is likely the most important setting for scaling a Mumble install, The default maximum Bandwidth is 72000bps Per User. Reducing this value will cause your clients to automatically scale back their bandwidth transmitted, while causing a reduction in voice quality. A value thats still high may cause robotic voices or users with bad connections to drop due entirely due to network load. Please tune this value to your individual needs, the below scale may provide a rough starting point. 72000 - Superior voice quality - Less than 50 users. 54000 - No noticeable reduction in quality - 50+ Users or many channels with active audio. 36000 - Mild reduction in quality - 100+ Users 30000 - Noticeable reduction in quality but not function - 250+ Users ### Forcing Opus A Mumble server by default, will fall back to the older CELT codec as soon as a single user connects with an old client. This will significantly reduce your audio quality and likely place higher load on your server. We *highly* reccommend setting this to Zero, to force OPUS to be used at all times. Be aware any users with Mumble clients prior to 1.2.4 (From 2013...) Will not hear any audio. Our default config sets this as follows ```docker mumble-authenticator: environment: `MUMBLE_CONFIG_opusthreshold=0` ``` ### AutoBan and Rate Limiting The AutoBan feature has some sensible settings by default, You may wish to tune these if your users keep locking themselves out by opening two clients by mistake, or if you are receiving unwanted attention This too, is set to a sensible configuration by default. Take note on upgrading older installs, as this may actually be set too restrictively and will rate-limit your admins accidentally, take note of the configuration in ```docker mumble-authenticator: environment: MUMBLE_CONFIG_messagelimit= MUMBLE_CONFIG_messageburst= MUMBLE_CONFIG_autobanAttempts=10 MUMBLE_CONFIG_autobanTimeframe=120 MUMBLE_CONFIG_autobanTime=30 MUMBLE_CONFIG_autobanSuccessfulConnections=false ``` ### "Suggest" Options There is no way to force your users to update their clients or use Push to Talk, but these options will throw an error into their Mumble Client. We suggest using Mumble 1.4.0+ for your server and Clients, you can tune this to the latest Patch version. If Push to Talk is to your tastes, configure the suggestion as follows ```docker mumble-authenticator: environment: MUMBLE_CONFIG_suggestVersion=s1.4.287 MUMBLE_CONFIG_suggestPushToTalk=true ``` ## General notes ### Server password With the default Mumble configuration your mumble server is public. Meaning that everyone who has the address can at least connect to it and might also be able join all channels that don't have any permissions set (Depending on your ACL configured for the root channel). We have changed this behaviour by setting a Server Password by default, to change this password modify `MUMBLE_SERVERPASSWORD` in `.env`. Restart the container to apply the change. ```shell docker compose restart mumble-server ``` It is not recommended to share/use this password, instead use the Mumble Authenticator whenever possible.