Conflict Roundcube / Custom Webapp

:uk:

My YunoHost server

Hardware: Raspberry Pi 2 Model B Rev 1.1 at home
YunoHost version: 11.2.5 (stable)
I have access to my server : Through SSH | through the webadmin
Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : no

If your request is related to an app, specify its name and version:

  • Custom Webapp 1.0~ynh15
  • Roundcube 1.6.0~ynh4

Description of my issue

I tried to install Roundcube.
When attempting to install Roundcube, I set /webmail as the “URL path (after the domain) where this application should be installed”.
This failed (error message translated from french) :

This URL is unavailable or conflicts with an existing application :
* www.mondomaine.fr/ → Custom Webapp (my_webapp)

Knowing that the “Custom Webapp (my_webapp)” in question is the PHP code of the website I’ve been hosting for years with YUnoHost…

In the Custom Webapp (my_webapp) application details, I see that I can “Modify this application’s access URL (domain and/or path)”, which is currently https://www.mondomaine.fr/ (at the root).
Should I move Custom Webapp (my_webapp) to a folder (example: https://www.mondomaine.fr/site ), and click on the “Set as default” button, so that the visitor doesn’t have to add “/site” to the URL?

Forgive all these questions, but as this is a “production” machine (online, that is…), I prefer to ask before doing anything stupid.


:fr:

Mon serveur YunoHost

Matériel: Raspberry Pi 2 Model B Rev 1.1 à la maison
Version de YunoHost: 11.2.5 (stable)
J’ai accès à mon serveur : En SSH | Par la webadmin
Êtes-vous dans un contexte particulier ou avez-vous effectué des modificiations particulières sur votre instance ? : non

Si votre requête est liée à une application, précisez son nom et sa version:

  • Custom Webapp 1.0~ynh15
  • Roundcube 1.6.0~ynh4

Description du problème

J’ai tenté d’installer Roundcube.
Lors de la tentative d’installation de Roundcube, j’ai mis /webmail comme “chemin d’URL (après le domaine) où cette application doit être installée”.
J’ai essuyé un échec :

Cette URL n'est pas disponible ou est en conflit avec une application existante :
* www.mondomaine.fr/ → Custom Webapp (my_webapp)

Sachant que la “Custom Webapp (my_webapp)” en question est le code PHP du site web que j’héberge depuis des années avec YUnoHost…

Dans le détail de l’application Custom Webapp (my_webapp), je vois que je peux “Modifier l’URL d’accès de cette application (domaine et/ou chemin)”, qui est actuellement https://www.mondomaine.fr/ (à la racine donc).
Faudrait-il que je déplace Custom Webapp (my_webapp) vers un dossier (exemple : https://www.mondomaine.fr/site ), et que je clique sur le bouton “Définir par défaut”, pour que le visiteur n’ait pas à ajouter “/site” dans l’URL ?

Pardonnez toutes ces questions, mais s’agissant d’une machine “de production” (en ligne, quoi…), je préfère me renseigner avant de faire des bêtises.

Cobus.

Yes indeed, that should be the most straightforward way to fix the issues :+1:

No worries, thanks for the detailed and clear post :+1:

:uk:
Thanks for your answer, @Aleks !

I tried to move Custom Webapp (my_webapp) to a folder and clicked on the “Set as default” button.
As a result, one can type https://www.mondomaine.fr/ and be redirected to https://www.mondomaine.fr/site but the complete new path appears in the URL (this is not what I want), and all links between pages are broken (they miss the new /site subfolder in their URL). I could fix the latter, but clean URLs seem important to me.

What other options do I have to solve the original problem (the conflict between Roundcube and Custom Webapp) ?


:fr:
Merci pour ta réponse, @Aleks !

J’ai essayé de déplacer Custom Webapp (my_webapp) dans un dossier et j’ai cliqué sur le bouton “Définir par défaut”.
En conséquence, on peut taper https://www.mondomaine.fr/ et être redirigé vers https://www.mondomaine.fr/site mais le nouveau chemin complet apparaît dans l’URL (ce n’est pas ce que je veux), et tous les liens entre les pages sont cassés (il leur manque le nouveau sous-dossier /site dans leur URL). Je pourrais corriger ce dernier point, mais il me semble important d’avoir des URLs propres.

Quelles sont les autres options dont je dispose pour résoudre le problème initial (le conflit entre Roundcube et Custom Webapp) ?

Cobus.

:uk:
One solution I can think of, is host another domain on my server : webmail.mondomaine.fr (a subdomain, that is), and install Roundcube at the root of this subdomain.
But I want to send and receive e-mails with our usual address : info@mondomaine.fr , not info@webmail.mondomaine.fr
Is this achieveable without too much command line voodoo ?
What DNS records should I then create ?
Will I have Reverse DNS problems ?

@TheWatcher did something similar in Guide configuration Yunohost, but he used a lot of command line customization. If I do the same, I will be on my own when problems arise. Almost 7 years later, I hope there is a more standard procedure.

@Aleks and other YUnoHost wizards : what are your thoughts ?


:fr:
Une solution qui me vient à l’esprit est d’héberger un autre domaine sur mon serveur : webmail.mondomaine.fr (un sous-domaine, donc), et d’installer Roundcube à la racine de ce sous-domaine.
Mais je veux envoyer et recevoir des e-mails avec notre adresse habituelle : info@mondomaine.fr , et non pas info@webmail.mondomaine.fr.
Est-ce réalisable sans trop de sorcellerie en ligne de commande ?
Quels enregistrements DNS dois-je alors créer ?
Aurai-je des problèmes de Reverse DNS ?

@TheWatcher a fait quelque chose de similaire dans Guide configuration Yunohost, mais il a utilisé beaucoup de sur-mesure en ligne de commande. Si je fais la même chose, je serai livré à moi-même en cas de problème. Presque 7 ans plus tard, j’espère qu’il existe une procédure plus standard.

@Aleks et les autres bons génies de YUnoHost : qu’en pensez-vous ?

Cobus.

:uk:
I’ve cloned my microSD card to another, identical one. I can now run YUnoHost tests, and go back to the original microSD if necessary (for DNS tests, however, I’ll be working without a safety net).

Originally, I only created one domain in YUnoHost : www.mondomaine.fr .
I asked for web requests to mondomaine.fr to be redirected to www.mondomaine.fr (automatic addition of the www).
I had a single YUnoHost application: Custom Webapp (my_webapp) which contained the PHP code for my website.

I just tested something : I created a second domain in YUnoHost : webmail.mondomaine.fr . I was able to install the Roundcube application there.
But when I wanted to create a YUnoHost user named “info” (to receive e-mails with our usual address: info@mondomaine.fr), I had the choice between info@www.mondomaine.fr and info@webmail.mondomaine.fr .

As a result, I’m under the impression that I need to create a third YUnoHost domain mondomaine.fr (without www or webmail) to be able to create the user info@mondomaine.fr .

Am I right, or wrong ?

If I do this, I’ll get this YUnoHost configuration:

And I’d have two users:

What are your thoughts ?


:fr:
J’ai dupliqué ma carte microSD sur une autre, identique. Je peux maintenant faire des tests YUnoHost, et revenir sur la microSD originale si besoin (en revanche, pour les tests DNS, je travaillerai sans filet).

À l’origine je n’avais créé qu’un domaine dans YUnoHost : www.mondomaine.fr .
J’avais demandé que les requêtes web sur mondomaine.fr soient redirigées sur www.mondomaine.fr (ajout automatique du www).
J’avais une seule application YUnoHost : Custom Webapp (my_webapp) qui contenait le code PHP de mon site web.

Je viens de faire un essai : j’ai créé un deuxième domaine dans YUnoHost : webmail.mondomaine.fr . J’ai pu y installer l’application Roundcube.
Mais quand j’ai voulu créer un utilisateur YUnoHost nommé “info” (pour recevoir des e-mails avec notre adresse habituelle : info@mondomaine.fr), j’ai eu le choix entre info@www.mondomaine.fr et info@webmail.mondomaine.fr .

Du coup, j’ai l’impression qu’il faut que je crée un troisième domaine YUnoHost mondomaine.fr (sans www ni webmail) pour pouvoir créer l’utilisateur info@mondomaine.fr .

J’ai bon, ou pas ?

Si je fais ça, j’obtiendrai cette configuration YUnoHost :

Et j’aurais deux utilisateurs :

Qu’en pensez-vous ?

Cobus.

:uk:
I did what I described in the previous post, and asked YUnoHost to modify my DNS records.
Everything went fine.

I now have this YUnoHost configuration:

Each of these (sub)domains has its own Let’s Encrypt certificate (obtained through the YUnoHost web interface).

And I have two users:

By typing webmail.mondomaine.fr in my web browser, after identification I get the Roundcube interface.
I’m receiving and sending e-mails without any problem at the moment.

But I can’t import my old emails with mbsync/isync (more details in Sauvegarde boite mail) :

Error, certificate owner does not match hostname webmail.mondomaine.fr

and Thunderbird complains:

Wrong site
The certificate belongs to a different site

It seems that mbsync/isync and Thunderbird are using the wrong certificate. How can I solve this problem?


:fr:
J’ai fait ce qui est décrit dans le message précédent, et ai demandé à YUnoHost de modifier mes enregistrements DNS.
Tout s’est bien passé.

J’ai maintenant cette configuration YUnoHost :

Chacun de ces (sous)domaines a son propre certificat Let’s Encrypt (obtenu via l’interface web de YUnoHost).

Et j’ai deux utilisateurs :

En tapant webmail.mondomaine.fr dans mon navigateur internet, après identification j’obtiens l’interface Roundcube.
Je reçois et envoie des courriels sans problème pour le moment.

Mais je ne parviens pas à importer mes anciens courriels avec mbsync/isync (plus de détails dans Sauvegarde boite mail) :

Error, certificate owner does not match hostname webmail.mondomaine.fr

et Thunderbird se plaint :

Wrong site
The certificate belongs to a different site

Il semble que mbsync/isync et Thunderbird n’utilisent pas le bon certificat. Comment résoudre ce problème ?

Cobus.

:uk:
I found the solution : I asked YUnoHost to consider that the main domain is mondomaine.fr
This solved my problem with certificates.


:fr:
J’ai trouvé la solution : j’ai demandé à YUnoHost de considérer que le domaine principal était mondomaine.fr
Ça a résolu mon problème de certificat.

Cobus.

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.