1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/discourse_ynh.git synced 2024-09-03 18:26:18 +02:00

Create admin user during installation

This commit is contained in:
Jimmy Monin 2018-04-03 18:28:04 +02:00
parent b129d88a6b
commit 92f535009e

View file

@ -190,16 +190,17 @@ $rake_exec db:migrate
$rake_exec assets:precompile)
#=================================================
# INSTALL PLUGINS
# CREATE ADMIN USER
#=================================================
# # Install LDAP plugin
# ynh_setup_source "$final_path/plugins" ldap-auth
# # Set permissions to app files
# chown -R $app: $final_path/plugins
# # TODO install all in one shot?
# (cd "$final_path"
# exec_as $app bin/rake RAILS_ENV=production assets:precompile)
# Create a random password
admin_pwd=$(ynh_string_random)
(cd "$final_path"
sudo -u discourse bin/rake RAILS_ENV=production admin:create <<< "$admin_mail
$admin_pwd
$admin_pwd
y
")
#=================================================
# CONFIGURE PLUGINS