diff options
| -rw-r--r-- | scripts/install | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/scripts/install b/scripts/install index da834f5..7b3e789 100644 --- a/scripts/install +++ b/scripts/install @@ -209,10 +209,10 @@ ynh_replace_string "#SMTP_OPENSSL_VERIFY_MODE=peer" "SMTP_OPENSSL_V cd "$final_path/live" su mastodon <<INSTALL $final_path/.rbenv/versions/2.5.3/bin/gem install bundler - $final_path/live/bin/bundle install -j$(getconf _NPROCESSORS_ONLN) --deployment --without development test --quiet + $final_path/live/bin/bundle install -j$(getconf _NPROCESSORS_ONLN) --deployment --without development test yarn install --production --no-progress --non-interactive --silent echo "SAFETY_ASSURED=1">> .env.production - RAILS_ENV=production $final_path/live/bin/bundle exec rails db:migrate --quiet + RAILS_ENV=production $final_path/live/bin/bundle exec rails db:setup --quiet RAILS_ENV=production $final_path/live/bin/bundle exec rails assets:precompile --quiet INSTALL ) @@ -222,6 +222,8 @@ INSTALL #================================================= # Create a dedicated systemd config +ynh_replace_string "__PORT_WEB__" "$port_web" "../conf/mastodon-web.service" +ynh_replace_string "__PORT_STREAM__" "$port_stream" "../conf/mastodon-streaming.service" ynh_add_systemd_config "$app-web" "mastodon-web.service" ynh_add_systemd_config "$app-sidekiq" "mastodon-sidekiq.service" ynh_add_systemd_config "$app-streaming" "mastodon-streaming.service" @@ -237,7 +239,7 @@ account = Account.create!(username: '$admin_mastodon') user = User.create!(email: '$admin_mastodon_mail', password: '$admin_pass', account: account) CREATEUSER su mastodon <<SETADMIN -RAILS_ENV=production bin/tootctl accounts modify $admin_mastodon --confirmed +RAILS_ENV=production bin/tootctl accounts modify $admin_mastodon --confirm RAILS_ENV=production bin/tootctl accounts modify $admin_mastodon --role admin SETADMIN ) @@ -286,8 +288,8 @@ systemctl reload nginx message="Mastodon was successfully installed :) Please open 'https://$domain$path_url' -The admin username is: '$admin_mastodon_mail' -The admin password is: '$admin_pass' +The admin username is: $admin_mastodon_mail +The admin password is: $admin_pass If you facing an issue or want to improve this app, please open a new issue in this project: https://github.com/YunoHost-Apps/mastodon_ynh" ynh_send_readme_to_admin "$message" "$admin_mastodon" |
