[Peertube] login not working for admin user

:uk:/:us:

My YunoHost server

Hardware: ordoidhc1 / lxd-lxc / debian buster
YunoHost version: 4.3.4.2 (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

Description of my issue

I install the peertube app from the web interface
I receive the mail with passwork config
I go inside root account then insert the ldap configuration then save
I log out
I try to log with my ynh account (not the email but i am the administrador)
peertube tell me that my user does not exist

Nom d'utilisateur ou mot de passe incorrects. 

:fr:

Mon serveur YunoHost

Matériel: ordoidhc1 / lxd-lxc / debian buster
Version de YunoHost: 4.3.4.2 (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

Description du problème

J’installe l’app peertube depuis l’interface web
je recois le mail avec le mot de pass root
je rentre dans l’interface d’admin de peertube avec l’user root pour insert la configuration du plugin LDAP
je sauvegarde
Je sort de la session admin
Je tente de me logger avec mon nom d’utilsateur ynh (pas le mail mais je suis l’admin aussi)
peertube me dit que mon utilisateur n’existe pas. ou mot de passe incorrect

Nom d'utilisateur ou mot de passe incorrects. 

:es: /:chile: :

Mi servidor YunoHost

Material: ordoidhc1 / lxd-lxc / debian buster
Verción de YunoHost: 4.3.4.2 (stable).
Accesso: En SSH | webadmin
¿ hiciste una configuracion particular ? : no

Descripción del problema

installo la app peertube desde la web
recibo el mail con el pass root
entro en la interface admin de peertube con el usuario root para insertar la configuraión del plugin LDAP
guardo
quito la session admin
me loggeo con mi usuario ynh (no el correo pero soy admin tambien)
peertube me dice que el usuario no existe o la contraseña es incorrecta

Nom d'utilisateur ou mot de passe incorrects. 

Hi,

The first login is quite difficult to figure out!

The Yunohost users don’t work, you need to login as ‘root’ the first time. What is the password? It is mailed to one of your Yunohost mailaddresses. If you don’t know which one, you can reset it this way after loging in to your Yunohost:

$ sudo su - 
# cd /var/www/peertube 
# sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run reset-password -- -u root

> peertube@3.4.1 reset-password /var/www/peertube
> node ./dist/scripts/reset-password.js "-u" "root"

New password?
User password updated.

If you try to do it for a non existing user, the script will freak out with a scary error in many colours.

After that you can log in (as Peertube root, not Yunohost root) and create additional users.

Good luck!

PS: if it (also) works for you, would you mind translating the solution to the languages you know? My French is not good enough to be of much help here, and my Spanish not worth noting at all :stuck_out_tongue: )

It seems that i don’t tell well what i mean.

I can connect with root user and root password received by mall
But during the installation i put my personal mail in the form.

So i can’t loggme in with my ynh user and password.
As peertube root user seems to go over ldap user when email of peertube root account is the same of ldap one account.

Maybe in the install process the mail should be used only to send the root password and set the mail of the root account to admin@domain.tld.
or sert the root user name as ldap username.

I think the synchronization between Yunohost users and Peertube users does not work. The first time I tried Peertube, I expected the users to exist, and gave up because I could not log in.

Now I have a couple of Peertube instances via Yunohosts (and I am very excited about how Peertube works), but none of them have the Yunohost users available: I have to add them manually in Peertube.

I think you can try it now. Times ago it was not working for me too. But now, except for the root/admin user, its working.

Just create users in ynh and verify he LDAP plugin configuration

To enable LDAP authentication open https://sub.domain.tld/admin/plugins/show/peertube-plugin-auth-ldap
Complete with the following informations :

  • URL: ldap://127.0.0.1
  • Insecure TLS : checked
  • Search base : ou=users,dc=yunohost,dc=org

After user first authentication on peertune the user appear in the peertube userlist.

And more you can automatically set admin moderators and users right creating groups in ynh and setting LDAP parameters in LDAP peertube plugin
In group base : ou=groups,dc=yunohost,dc=org
In admin dn : cn=goupname,ou=groups,dc=yunohost,dc=org

1 Like

Great! I will try it the next time for sure, and start with configuring the plugin on the current installation.

Will that make SSO work, or will it configure identical users and query LDAP when logging in, but you still have to log in when visiting Peertube?

Thanks for the example configuration, sorry I could not actually help you with your problem.

Still have to log in when visiting Peertube

Don’t worry not always people can answer mis questions :wink:

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