--- author: XMRonly date: 2025-05-22 gitea_url: "http://git.nowherejezfoltodf4jiyl6r56jnzintap5vyjlia7fkirfsnfizflqd.onion/nihilist/blog-contributions/issues/322" xmr: 8AHNGepbz9844kfCqR4aVTCSyJvEKZhtxdyz6Qn8yhP2gLj5u541BqwXR7VTwYwMqbGc8ZGNj3RWMNQuboxnb1X4HobhSv3 --- ## **Remote Hosting SimpleX Servers** Before diving into server hosting i will suggest going over the simplex client tutorial [post](../privatesimplex/index.md): ### Requirements - A VPS running the latest Debian OS - A domain name (or subdomain) To start, we will need a domain name. A subdomain such as a free one obtained from **https://freedns.afraid.org** will also work. Create A record entries for smp.yourdomain.tld and xftp.yourdomain.tld and point them at the IP address of your VPS. ![](1.png) We will SSH into our VPS and set up our environment. ~ ❯ torsocks ssh root@145.223.79.150 The authenticity of host '145.223.79.150 (145.223.79.150)' can't be established. ED25519 key fingerprint is SHA256:AGZHyLpidaSu+ZE3cLFZ3KWxQq3Mx9rDH+HLVNF/okc. This key is not known by any other names. Are you sure you want to continue connecting (yes/no/[fingerprint])? yes Warning: Permanently added '145.223.79.150' (ED25519) to the list of known hosts. root@145.223.79.150's password: Linux srv636770 6.1.0-26-cloud-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.112-1 (2024-09-30) x86_64 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Wed Nov 20 21:05:02 2024 from 185.220.101.103 root@srv636770:~# Once connected, we will follow the [official instructions](https://docs.docker.com/engine/install/debian/) to install Docker. Run: # Add Docker's official GPG key: apt update apt install -y ca-certificates curl gnupg openssl vim install -m 0755 -d /etc/apt/keyrings curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg chmod a+r /etc/apt/keyrings/docker.gpg # Add the repository to Apt sources: echo \ "deb [arch="$(dpkg --print-architecture)" signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian \ "$(. /etc/os-release && echo "$VERSION_CODENAME")" stable" | \ tee /etc/apt/sources.list.d/docker.list > /dev/null apt update With the Docker apt repositories out of the way, install the Docker packages: apt install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin OPTIONAL: You can test everything is working up to this point by a deploying a test container to see some output. Run: docker run hello-world We will now set up a docker-compose.yml file with all the build instructions: vim docker-compose.yml Copy/paste the following and change the **ADDR** fields to your domain. HINT: It's **p** to paste in vim, then **ESC :wq** to write changes and quit the file. networks: simplex: services: simplex-smp-server: image: simplexchat/smp-server:v6.0.6 container_name: simplex-smp restart: unless-stopped ports: - "5223:5223" volumes: - ./simplex/smp/config:/etc/opt/simplex:Z - ./simplex/smp/logs:/var/opt/simplex:Z environment: - ADDR=smp.xmronly.us.to # - PASS=${SIMPLEX_PASSWORD} #for non public servers networks: - simplex security_opt: - no-new-privileges:true cap_drop: - ALL simplex-xftp-server: image: simplexchat/xftp-server:v6.1.3 container_name: simplex-xftp ports: - "443:443" restart: unless-stopped volumes: - ./simplex/xftp/config:/etc/opt/simplex-xftp:Z - ./simplex/xftp/logs:/var/opt/simplex-xftp:Z - ./simplex/xftp/files:/srv/xftp:X environment: - ADDR=xftp.xmronly.us.to - QUOTA=10gb #change to set your own quota networks: - simplex security_opt: - no-new-privileges:true cap_drop: - ALL A note about versioning: at the time of writing, there was an open [issue](https://github.com/simplex-chat/simplexmq/issues/1373) with the "latest" (v6.1.3) tag and HTTPS credentials for the SMP server. The most recent working version for the SMP server (v6.0.6) was definitively tagged here and the "latest" version for XFTP server (v6.1.3) was also definitively tagged to ensure working builds with the presented instructions. For reference, the "latest" version used in the [HackLiberty](https://forum.hackliberty.org/t/simplex-server-docker-installation-guide-smp-xftp/140) documentation for June 1st, 2024 is v5.8.0-beta.6 which is now several security fixes behind. Everything is now ready to be deployed. Run: docker compose up -d Run the following command to see the SMP and XFTP server addresses: echo "smp://$(