Install on shared hosting

Hi everyone,

I am hoping to install mattermost on a shared hosting at infomaniak
According to @marcokundt in the post below it might be doable with some tweaking.

So I do have ssh access but obviously no sudo
I wish to install it on a subdomain such as chat.mydomaine.ch

I tried the tarball install and I’m stuck as the commande : useradd --system --user-group mattermost returns useradd: command not found.

I am guessing it is because I do not have root access, but I think I could adjust the command to add the group somewhere else, any lead would be much appreciated as I’m a bit of a noob :wink:

Hey @SabRena,
My post from the past is still valid. This kind of setup has some drawbacks and you need to install it a bit differently.

I wish to install it on a subdomain such as chat.mydomaine.ch

For your unprivileged hosting you need either to use a port > 1024 (like the default 8065 because you can’t bind ports <1024 without root) which leads to a server URL like chat.foo.bar:8065 or if possible use a reverse proxy in front of Mattermost, if your hosting provider offers a free configurable reverse proxy (best would be Nginx).

I tried the tarball install and I’m stuck as the commande : useradd --system --user-group mattermost returns useradd: command not found.

Yes, some parts of the instructions will fail because you don’t have root. Though, Mattermost’s default deployment from tarball assumes it ends up in /opt and is being run as an unprivileged user called mattermost. For this to setup you need root, but it’s not a must to deploy it that way. In your case you need to use the existing user of your hosting and run Mattermost from there. So, when you come across something with a mattermost user/group in the deploy commands, you need to use your username/group instead and instead of everything /opt use your home (or the path where you extracted the tarball).
When it comes to the systemd service; this is might not be possible because of missing access due to shared hosting (and the instructions need root again. But could also be done without root with user services). Here you need to start the mattermost binary otherwise (e.g. in a tmux, screen, usw).

Marco