[12:14:36]
<tituspijean> > <@deelarjohn:matrix.org> Thx, how does this work, since my router is a Starlink one and I am afraid, I do not have many possibilities…..
you could run your own DNS server (with adguard for example), where you can set the answer for your domain to the server's VPN address. You would need to set all your clients to use that DNS server
[15:47:15]
<vanitarium> Hello yunohosters, I need some help: I tried to upgrade mattermost from development branch but it failed. Trying to restore it from pre-upgrade backup fails. Here is the log: https://paste.yunohost.org/raw/ekedekokuc
[15:57:24]
<Aleks (he/him/il/lui)> saw your message on the forum but i don't understand ... the systemctl output feels as if it's missing an argument in the startup command ... but the ExecStart doesn't have any arg in the original code and it works fine on plenty of setups ... https://github.com/YunoHost-Apps/mattermost\_ynh/blob/testing/conf/systemd.service#L10
[15:59:39]
<vanitarium> Merci... I do not understand either what has happened. The log does not show what error it is so I am lost. The ExecStart= /var/www/mattermost/bin/mattermost line seems to be correct to me
[16:01:49]
<vanitarium> I am trying to install directly from the testing branch just now and see if I can restore after uninstalling it again... is there no way to force restore over an installed app?
[16:06:17]
<Aleks (he/him/il/lui)> apparently you already had the same issue like 1.5 years ago ..? https://github.com/YunoHost-Apps/mattermost_ynh/issues/401
[16:08:02]
<Aleks (he/him/il/lui)> and https://forum.yunohost.org/t/mattermost-restore-failure/22605
[16:08:29]
<Aleks (he/him/il/lui)> it's not clear to me if you were able to fix the issue or not at that time
[16:10:01]
<vanitarium> No I did not find a solution except of restoring the wholw server from backup by reinstall and restore: that is what I remeber then.
[16:10:57]
<vanitarium> I have just installed the mattermost testing branch. I will now uninstall it and try the backup again....
[16:12:19]
<vanitarium> How can I restore the data from the previous installation? Is there a method by manually restoring the database,etc?
[16:12:35]
<Aleks (he/him/il/lui)> there's no point reinstalling the app before restoring a backup since the point is that you need to remove the app before restoring it
[16:13:06]
<Aleks (he/him/il/lui)> anyway, we can trick the backup to "not fail" though the service will probably be broken anyway at the end ... but at least that could allow debugging / fixing manually things afterward
[16:13:38]
<Aleks (he/him/il/lui)> in the backup archive, under something like `mattermost/settings/scripts/restore` you should find the restore script
[16:14:02]
<Aleks (he/him/il/lui)> and near the end there should be this line `ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="Started Mattermost"`
[16:14:38]
<Aleks (he/him/il/lui)> aaaaand let's prefix it with an `#` to comment it out such that it looks like:
```
# ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="Started Mattermost"
```
[16:14:59]
<Aleks (he/him/il/lui)> and then save this change in the archive somehow, reupload it to the server if needed, and restore it ?
[16:16:54]
<vanitarium> OK, thanks will try right now... I have got the extracted archive on the server in /home/yunohost.backup/archives/temp and will need to tar it and save it ... wish me luck or "bon courage"
[16:35:00]
<vanitarium> I am sorry but it failed see log here https://paste.yunohost.org/raw/xijurefuja
[16:47:55]
<Aleks (he/him/il/lui)> mokay but it id try to start the service so it feels like the line wasnt actually commented in the restore script ? x_x
[17:04:50]
<vanitarium> sorry there was a problem with uploading the modified file.... now it went to the end of the restore
[17:04:58]
<vanitarium> here is the log
[17:05:05]
<vanitarium> metadata:
ended_at: 2024-07-22 18:02:41
env:
BASH_XTRACEFD: 7
YNH_APP_ACTION: restore
YNH_APP_BACKUP_DIR: /home/yunohost.backup/tmp/mattermost-pre-upgrade1/apps/mattermost/backup
YNH_APP_BASEDIR: /home/yunohost.backup/tmp/mattermost-pre-upgrade1/apps/mattermost/settings
YNH_APP_ID: mattermost
YNH_APP_INSTANCE_NAME: mattermost
YNH_APP_INSTANCE_NUMBER: 1
YNH_APP_MANIFEST_VERSION: 9.9.1~ynh1
YNH_APP_PACKAGING_FORMAT: 2.0
YNH_ARCH: amd64
YNH_BACKUP_CSV: /home/yunohost.backup/tmp/mattermost-pre-upgrade1/backup.csv
YNH_BACKUP_DIR: /home/yunohost.backup/tmp/mattermost-pre-upgrade1
YNH_CWD: /home/yunohost.backup/tmp/mattermost-pre-upgrade1/apps/mattermost/backup
YNH_DEBIAN_VERSION: bullseye
YNH_HELPERS_VERSION: 2
YNH_INTERFACE: cli
YNH_STDRETURN: /tmp/tmp9t5wt_c3/stdreturn
error: None
interface: cli
operation: backup_restore_app
parent: None
related_to:
- app
- mattermost
started_at: 2024-07-22 18:02:06
success: True
yunohost_version: 11.2.21.2
metadata_path: /var/log/yunohost/categories/operation/20240722-170206-backup_restore_app-mattermost.yml
name: 20240722-170206-backup_restore_app-mattermost
[17:06:05]
<Aleks (he/him/il/lui)> mokay so now i suppose mattermost should be sort of restored, but the app is "not working" and/or the corresponding service is down, right ?
[17:07:18]
<vanitarium> right it is not working
[17:08:11]
<Aleks (he/him/il/lui)> and `sudo systemctl restart mattermost` followed by `sudo journalctl -u mattermost -n 100` should probably show the same error than before in the previous restore attempts ?
[17:08:25]
<vanitarium> Diagnosis is saying mattermost service is failed
[17:08:41]
<Aleks (he/him/il/lui)> (or you can also try from the webadmin to Start/Restart the service and look at the logs)
[17:09:47]
<orhtej2> Based on logs i sew on the forum unit file is borked, should start `mattermost server`
[17:09:52]
<vanitarium> this is error from sysctl restart command Job for mattermost.service failed because the control process exited with error code.
[17:11:53]
<Aleks (he/him/il/lui)> yeah let's try what orhtej2 is mentioning and let's edit the service conf with `sudo nano /etc/systemd/system/mattermost.service` (i think, not 100% i don't have a typo in there), and add `server` at the end of the ExecStart command such that it looks like `ExecStart= /var/www/mattermost/bin/mattermost server`
[17:12:12]
<Aleks (he/him/il/lui)> then `sudo systemctl daemon-reload` and retry `sudo systemctl restart mattermost`
[17:12:19]
<vanitarium> and journalctl gives error mattermost.service: Main process exited, code=exited, status=1/FAILURE
Jul 22 18:10:04 liquorstane.eu systemd[1]: mattermost.service: Failed with result 'exit-code'.
Jul 22 18:10:04 liquorstane.eu systemd[1]: Failed to start Mattermost: collaboration platform.
Jul 22 18:10:04 liquorstane.eu systemd[1]: mattermost.service: Consumed 9.223s CPU time.
Jul 22 18:10:14 liquorstane.eu systemd[1]: mattermost.service: Scheduled restart job, restart counter is at 3.
Jul 22 18:10:14 liquorstane.eu systemd[1]: Stopped Mattermost: collaboration platform.
Jul 22 18:10:14 liquorstane.eu systemd[1]: mattermost.service: Consumed 9.223s CPU time.
Jul 22 18:10:14 liquorstane.eu systemd[1]: Starting Mattermost: collaboration platform...
[17:12:41]
<Aleks (he/him/il/lui)> (but even if that works I'm confused how the hell mattermost works so far for other peolpe ...)
[17:13:38]
<vanitarium> ok will try orhtej2 suggestion
[17:17:30]
<vanitarium> failed again with systemctl status mattermost.service
● mattermost.service - Mattermost: collaboration platform
Loaded: loaded (/etc/systemd/system/mattermost.service; enabled; vendor preset: enabled)
Active: activating (auto-restart) (Result: exit-code) since Mon 2024-07-22 18:16:54 BST; 1s ago
Process: 122259 ExecStart=/var/www/mattermost/bin/mattermost server (code=exited, status=1/FAILURE)
Main PID: 122259 (code=exited, status=1/FAILURE)
CPU: 9.079s
[17:21:23]
<Aleks (he/him/il/lui)> please run `sudo journalctl -u mattermost --no-pager --no-hostname -n 50`
[17:24:34]
<vanitarium> -- Journal begins at Thu 2023-06-22 21:13:22 BST, ends at Mon 2024-07-22 18:23:55 BST. --
Jul 22 18:22:17 mattermost[123610]: Error: Must enable Forward80To443 when using LetsEncrypt
Jul 22 18:22:17 systemd[1]: mattermost.service: Main process exited, code=exited, status=1/FAILURE
Jul 22 18:22:17 systemd[1]: mattermost.service: Failed with result 'exit-code'.
Jul 22 18:22:17 systemd[1]: Failed to start Mattermost: collaboration platform.
Jul 22 18:22:17 systemd[1]: mattermost.service: Consumed 8.705s CPU time.
Jul 22 18:22:27 systemd[1]: mattermost.service: Scheduled restart job, restart counter is at 18.
Jul 22 18:22:27 systemd[1]: Stopped Mattermost: collaboration platform.
Jul 22 18:22:27 systemd[1]: mattermost.service: Consumed 8.705s CPU time.
Jul 22 18:22:27 systemd[1]: Starting Mattermost: collaboration platform...
Jul 22 18:22:42 mattermost[123689]: Error: Must enable Forward80To443 when using LetsEncrypt
Jul 22 18:22:42 systemd[1]: mattermost.service: Main process exited, code=exited, status=1/FAILURE
Jul 22 18:22:42 systemd[1]: mattermost.service: Failed with result 'exit-code'.
Jul 22 18:22:42 systemd[1]: Failed to start Mattermost: collaboration platform.
Jul 22 18:22:42 systemd[1]: mattermost.service: Consumed 8.560s CPU time.
Jul 22 18:22:52 systemd[1]: mattermost.service: Scheduled restart job, restart counter is at 19.
Jul 22 18:22:52 systemd[1]: Stopped Mattermost: collaboration platform.
Jul 22 18:22:52 systemd[1]: mattermost.service: Consumed 8.560s CPU time.
Jul 22 18:22:52 systemd[1]: Starting Mattermost: collaboration platform...
Jul 22 18:22:56 mattermost[123771]: Error: Must enable Forward80To443 when using LetsEncrypt
Jul 22 18:22:56 systemd[1]: mattermost.service: Main process exited, code=exited, status=1/FAILURE
Jul 22 18:22:56 systemd[1]: mattermost.service: Failed with result 'exit-code'.
Jul 22 18:22:56 systemd[1]: Failed to start Mattermost: collaboration platform.
Jul 22 18:22:56 systemd[1]: mattermost.service: Consumed 8.680s CPU time.
Jul 22 18:23:06 systemd[1]: mattermost.service: Scheduled restart job, restart counter is at 20.
Jul 22 18:23:06 systemd[1]: Stopped Mattermost: collaboration platform.
Jul 22 18:23:06 systemd[1]: mattermost.service: Consumed 8.680s CPU time.
Jul 22 18:23:06 systemd[1]: Starting Mattermost: collaboration platform...
Jul 22 18:23:17 mattermost[123854]: Error: Must enable Forward80To443 when using LetsEncrypt
Jul 22 18:23:17 systemd[1]: mattermost.service: Main process exited, code=exited, status=1/FAILURE
Jul 22 18:23:17 systemd[1]: mattermost.service: Failed with result 'exit-code'.
Jul 22 18:23:17 systemd[1]: Failed to start Mattermost: collaboration platform.
Jul 22 18:23:17 systemd[1]: mattermost.service: Consumed 8.285s CPU time.
Jul 22 18:23:27 systemd[1]: mattermost.service: Scheduled restart job, restart counter is at 21.
Jul 22 18:23:27 systemd[1]: Stopped Mattermost: collaboration platform.
Jul 22 18:23:27 systemd[1]: mattermost.service: Consumed 8.285s CPU time.
Jul 22 18:23:27 systemd[1]: Starting Mattermost: collaboration platform...
Jul 22 18:23:39 mattermost[123940]: Error: Must enable Forward80To443 when using LetsEncrypt
Jul 22 18:23:39 systemd[1]: mattermost.service: Main process exited, code=exited, status=1/FAILURE
Jul 22 18:23:39 systemd[1]: mattermost.service: Failed with result 'exit-code'.
Jul 22 18:23:39 systemd[1]: Failed to start Mattermost: collaboration platform.
Jul 22 18:23:39 systemd[1]: mattermost.service: Consumed 8.534s CPU time.
Jul 22 18:23:49 systemd[1]: mattermost.service: Scheduled restart job, restart counter is at 22.
Jul 22 18:23:49 systemd[1]: Stopped Mattermost: collaboration platform.
Jul 22 18:23:49 systemd[1]: mattermost.service: Consumed 8.534s CPU time.
Jul 22 18:23:49 systemd[1]: Starting Mattermost: collaboration platform...
Jul 22 18:23:55 mattermost[124020]: Error: Must enable Forward80To443 when using LetsEncrypt
Jul 22 18:23:55 systemd[1]: mattermost.service: Main process exited, code=exited, status=1/FAILURE
Jul 22 18:23:55 systemd[1]: mattermost.service: Failed with result 'exit-code'.
Jul 22 18:23:55 systemd[1]: Failed to start Mattermost: collaboration platform.
Jul 22 18:23:55 systemd[1]: mattermost.service: Consumed 8.429s CPU time.
[17:24:49]
<Aleks (he/him/il/lui)> https://aria.im/_matrix/media/v1/download/matrix.org/KdHOmhdIbptUjrNrhjGDpCNk
[17:26:00]
<vanitarium> yes I am empty of ideas specially after this:
[17:26:02]
<vanitarium> systemctl status mattermost.service
● mattermost.service - Mattermost: collaboration platform
Loaded: loaded (/etc/systemd/system/mattermost.service; enabled; vendor preset: enabled)
Active: activating (start) since Mon 2024-07-22 18:24:42 BST; 51s ago
Main PID: 124271 (mattermost)
Tasks: 12 (limit: 19038)
Memory: 295.8M
CPU: 7.269s
CGroup: /system.slice/mattermost.service
└─124271 /var/www/mattermost/bin/mattermost server
[17:26:19]
<Aleks (he/him/il/lui)> `Error: Must enable Forward80To443 when using LetsEncrypt` hmmm
[17:26:28]
<Aleks (he/him/il/lui)> that feels reminiscent of the initial story on the forum a while ago
[17:27:06]
<Aleks (he/him/il/lui)> did you do anything specific priori to all this at some point such as manually editing mattermost configuration, or maybe upgrading mattermost through mattermost itself instead of yunohost (i don't even know if that's a thing)
[17:28:27]
<vanitarium> Sorry, I only upgraded from yunohost command from the testing branch and that wrecked it all
[17:31:15]
<Aleks (he/him/il/lui)> can you share the ouput of `sudo grep LetsEncrypt /var/www/mattermost/config/config.json`
[17:37:11]
<vanitarium> SOLUTION: I modified nano /var/www/mattermost/config/config.json so that "UseLetsEncrypt": false, was set.
[17:38:39]
<vanitarium> That solved it and it now running fine as before.Thank you Aleks (he/him/il/lui) and orhtej2 for help, patience and knowledge supplied
[17:39:18]
<Aleks (he/him/il/lui)> i'm reasking but could it be that you manually changed this setting in mattermost's admin at some point ? x_x
[17:40:39]
<vanitarium> I did some time ago but not when the backup was created: it was running just fine... I wonder if the testing branch has that set to 'true'?
[17:41:14]
<Aleks (he/him/il/lui)> the testing has nothing to do with it, the issue was already in the backup, which is created prior to the upgrade (because the point is precisely to save the state *before* the upgrade)
[17:42:03]
<Aleks (he/him/il/lui)> it just sounds like changing the setting back a while ago did not break mattermost right away, because changing the setting did not restart the service, yet this effectively broke restarting the service ...
[17:42:05]
<vanitarium> but why was it running perfectly wellbefore??? I am at the end of my knowledge here ....
[17:42:28]
<Aleks (he/him/il/lui)> because changing the setting did not restart the server, yet it would have been unable to restart
[17:42:57]
<Aleks (he/him/il/lui)> this feels like a bug on mattermost's side in some sense
[17:42:58]
<vanitarium> You must be right ... it is the only explanation
[17:43:45]
<Aleks (he/him/il/lui)> (and to add to the confusion, mattermost CLI was complaining about the lack of argument, probably because the error system thought that was the error, yet it displayed another error once we added the `server` keyword)
[17:45:34]
<vanitarium> You got it right as most of the yunohost helpers: this needs to be put on the forum for others tom learn. I shall try and summarise it in the forum
[17:46:19]
<vanitarium> Thank you merci beaucoup....👍️🎉
[17:46:50]
<vanitarium> You got it right as most of the yunohost helpers: this needs to be put on the forum for others to learn. I shall try and summarise it in the forum
[17:57:47]
<vanitarium> Summary solution now on forum au revoir et a bientot
[17:58:16]
<Aleks (he/him/il/lui)> https://www.youtube.com/watch?v=IFS-njpx8SI
[17:58:41]
<vanitarium> 😅🤣😂
[22:08:15]
<broccoli> how do i prevent domain.tld/* from redirecting to yunohost login page?
[23:00:37]
<Aleks (he/him/il/lui)> by defining a default app