YunoHost-Apps / Experimental_helpers

6 stars 12 forks source link

Delete ynh_sanitize_name #49

Closed yalh76 closed 5 years ago

yalh76 commented 5 years ago

After more testing, this helper is not needed to help creating ldap users as proposed in https://github.com/YunoHost-Apps/Experimental_helpers/pull/48

There are limitations on yunohost users firstname and lastname like they can't include numbers so using $app even sanitized can't work.

Better to do something for and example app:

ldap_user="svc_${app}_ldap"
ldap_password=$(ynh_string_random --length=8)

create $ldap_user --firstname "SvcExampleLdap" --lastname "SvcExampleLdap" --mail ${ldap_user}@$domain --password $ldap_password -q 0

Sorry to haven't tested it more before doing the first PR.