mirror of
https://github.com/YunoHost-Apps/fab-manager_ynh.git
synced 2024-09-03 18:36:16 +02:00
Fix db creation: don't call migration but schema load and seed
This commit is contained in:
parent
21b49ccbeb
commit
0aada4d287
2 changed files with 2 additions and 1 deletions
|
@ -56,6 +56,7 @@ fabmanager_build_ui() {
|
|||
fabmanager_seed_db() {
|
||||
pushd "$install_dir"
|
||||
ynh_replace_string --match_string="DateTime.current" --replace_string="DateTime.current - 1.days" --target_file="$install_dir/db/seeds.rb"
|
||||
env_ruby bash -c "set -a; source '$install_dir/.env'; set +a ; RAILS_ENV=production ADMIN_EMAIL='$admin_mail' ADMIN_PASSWORD='$password' bin/bundle exec rails db:schema:load"
|
||||
env_ruby bash -c "set -a; source '$install_dir/.env'; set +a ; RAILS_ENV=production ADMIN_EMAIL='$admin_mail' ADMIN_PASSWORD='$password' bin/bundle exec rails db:seed"
|
||||
popd
|
||||
}
|
||||
|
|
|
@ -75,8 +75,8 @@ ynh_script_progression --message="Building app..." --weight=7
|
|||
fabmanager_build_ruby
|
||||
fabmanager_build_ui
|
||||
|
||||
fabmanager_migrate_db
|
||||
fabmanager_seed_db
|
||||
# fabmanager_migrate_db
|
||||
|
||||
ynh_secure_remove --file="$install_dir/.cache"
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue