Wednesday, April 26, 2023
apps@conference.yunohost.org
April
Mon Tue Wed Thu Fri Sat Sun
          1
2
3
4
5
6
7
8
9
10
11
12 13 14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
             

[16:39:30] <eric_G> in SnappyMail, the password-file is created after first opening the admin UI. I am looking for a way to open the admin UI during the install process to creat this password file so the admin password can be displayed in `POST_INSTALL.md file`.
[16:40:35] <eric_G> I tried `ynh_local_curl "/?admin"` without success
[16:57:29] <Aleks (he/him/il/lui)> anything special happen or does it just silently does nothing ?
[16:58:18] <eric_G> I get this:
```
Info: [++++++++............] > Setting up source files...
Info: [########+++++++++...] > Adding system configurations related to snappymail...
Warning: ./install: line 58: /var/www/snappymail/data/_data_/_default_/admin_password.txt: No such file or directory
Error: Unable to install snappymail: An error occurred inside the app installation script
Info: The operation 'Install the 'snappymail' app' could not be completed. Please share the full log of this operation using the command 'yunohost log share 20230426-163637-app_install-snappymail' to get help
Warning: Here's an extract of the logs before the crash. It might help debugging the error:
Info: DEBUG - }
Info: DEBUG - },
Info: DEBUG - second: {
Info: DEBUG - past: {
Info: DEBUG - one: "{0} second ago",
Info: DEBUG - other: "{0} seconds ago"
Info: DEBUG - },
Info: DEBUG - future: {
Info: DEBUG - one: "in {0} second",
Info: DEBUG - other: "in {0} seconds"
Info: DEBUG - }
Info: DEBUG - }
Info: DEBUG - },
Info: DEBUG - /* 'zero', 'one', 'two', 'few', 'many', 'other' */
Info: DEBUG - plural: n => 1 == n ? 'one' : 'other'
Info: DEBUG - }
Info: WARNING - ./install: line 58: /var/www/snappymail/data/_data_/_default_/admin_password.txt: No such file or directory
Info: DEBUG - ;</script></body></html>+ [[ yes == \n\o ]]
Info: DEBUG - + admin_password=
Info: DEBUG - + ynh_exit_properly

```
[16:59:07] <eric_G> https://github.com/YunoHost-Apps/snappymail_ynh/blob/8984f07dc5b8b568c3b8dd932b354bdd8903506b/scripts/install#L53-L60
[17:08:10] <Aleks (he/him/il/lui)> hmkay, do you have the full log ?
[17:09:18] <eric_G> yes sorry... https://paste.yunohost.org/raw/nugokakilo
[17:21:56] <Aleks (he/him/il/lui)> and supposedly just *opening* the page the first time is enough ? Not even login in is required ?
[17:22:11] <Aleks (he/him/il/lui)> (Or *opening* while being logged in on the SSO ?)
[17:29:45] <Aleks (he/him/il/lui)> https://github.com/the-djmaze/snappymail/blob/master/integrations/nextcloud/snappymail/lib/Migration/InstallStep.php#L65-L67
[17:30:00] <Aleks (he/him/il/lui)> sounds simpler to just yolocreate the file ourselves, this seems to just be base64 encoding
[17:33:41] <Aleks (he/him/il/lui)> ah but it's gonna get overwritten when opening the page the first time
[17:33:42] <Aleks (he/him/il/lui)> hmf
[17:39:13] <Aleks (he/him/il/lui)> why is this `integrations/nextcloud` tho x_x
[17:43:07] <eric_G> the file seems created when I open SnappyMail login page, not the `/?admin` part...
[17:44:49] <eric_G> > <@Alekswag:matrix.org> why is this `integrations/nextcloud` tho x_x

I think it is the SnappyMail app for Nextcloud integration
[17:44:56] <eric_G> but I am paraphrasing 😅
[17:45:22] <Aleks (he/him/il/lui)> > <@ericg:matrix.org> the file seems created when I open SnappyMail login page, not the `/?admin` part...

hmmokay but then can't you just call `ynh_local_curl "/"` ?
[17:45:47] <eric_G> I am trying now
[17:48:05] <Aleks (he/him/il/lui)> maybe `ynh_local_curl` does a `POST` and not a `GET` tho
[17:48:41] <Aleks (he/him/il/lui)> yeah it does a POST request
[17:48:46] <eric_G> It is failling https://paste.yunohost.org/raw/foqojoriyo
[17:52:04] <Aleks (he/him/il/lui)> i'd try this instead:

```
curl --silent --show-error --insecure --location --header "Host: $domain" --resolve "$domain:443:127.0.0.1" https://localhost$path
```
[17:53:18] <Aleks (he/him/il/lui)> ah but there's nothing saying it does a POST request here if no post param is provided o_O
[17:53:45] <Aleks (he/him/il/lui)> confusion intensifies
[18:05:24] <Aleks (he/him/il/lui)> eric_G: imho you should check `tail -n 30 /var/log/nginx/the.domain.tld-access.log` after the install to check what error code was returned exactly during the `curl`
[18:06:04] <Aleks (he/him/il/lui)> and same but without doing the curl + manually browsing to the page (which gonna trigger a shitload more entries because of CSS assets etc ... so maybe `tail -n 300` in that case)
[18:06:23] <Aleks (he/him/il/lui)> ah maybe also checking the `-error.log` in addition to the `-access.log`
[22:30:00] <Tril> Trying to set up vaultwarden, not able to login at all or create account. Looking for docs. https://github.com/YunoHost-Apps/vaultwarden_ynh links to "YunoHost documentation for this app" but it gives me an error: https://yunohost.org/en/app_vaultwarden
```
Server Error
Sorry, something went terribly wrong!

E_NOTICE - Trying to access array offset on value of type bool
```
[22:48:17] <orhtej2> > <@tril:hacknw.org> Trying to set up vaultwarden, not able to login at all or create account. Looking for docs. https://github.com/YunoHost-Apps/vaultwarden_ynh links to "YunoHost documentation for this app" but it gives me an error: https://yunohost.org/en/app_vaultwarden
> ```
> Server Error
> Sorry, something went terribly wrong!
>
> E_NOTICE - Trying to access array offset on value of type bool
> ```

Check admin email, you should have received access token there
[23:42:25] <Yunohost Git/Infra notifications> App mautrix_whatsapp rises from level 7 to 8 in job [#15245](https://ci-apps.yunohost.org/ci/job/15245) !
[23:53:27] <Yunohost Git/Infra notifications> App pgadmin failed all tests in job [#15246](https://ci-apps.yunohost.org/ci/job/15246) :(