mirror of
https://github.com/YunoHost-Apps/invidious_ynh.git
synced 2024-09-03 19:15:55 +02:00
Update install
This commit is contained in:
parent
393557ac6f
commit
fde7e7289b
1 changed files with 10 additions and 5 deletions
|
@ -135,13 +135,18 @@ ynh_app_setting_set --app=$app --key=final_path --value=$final_path
|
||||||
git clone https://github.com/iv-org/invidious "$final_path" --quiet
|
git clone https://github.com/iv-org/invidious "$final_path" --quiet
|
||||||
|
|
||||||
# Create a temporary directory
|
# Create a temporary directory
|
||||||
tmpdir="$(mktemp -d)"
|
# tmpdir="$(mktemp -d)"
|
||||||
cp -a "$final_path/config/sql/{channels.sql,videos.sql,channel_videos.sql,users.sql,session_ids.sql,nonces.sql,annotations.sql,playlists.sql,playlist_videos.sql}" "tmpdir/{channels.sql,videos.sql,channel_videos.sql,users.sql,session_ids.sql,nonces.sql,annotations.sql,playlists.sql,playlist_videos.sql}"
|
# cp -a "$final_path/config/sql/{channels.sql,videos.sql,channel_videos.sql,users.sql,session_ids.sql,nonces.sql,annotations.sql,playlists.sql,playlist_videos.sql}" "tmpdir/{channels.sql,videos.sql,channel_videos.sql,users.sql,session_ids.sql,nonces.sql,annotations.sql,playlists.sql,playlist_videos.sql}"
|
||||||
|
|
||||||
ynh_psql_execute_file_as_root --file="tmpdir/{channels.sql,videos.sql,channel_videos.sql,users.sql,session_ids.sql,nonces.sql.sql,annotations.sql,playlists.sql,playlist_videos.sql}" --database=$db_name
|
# ynh_psql_execute_file_as_root --file="tmpdir/{channels.sql,videos.sql,channel_videos.sql,users.sql,session_ids.sql,nonces.sql.sql,annotations.sql,playlists.sql,playlist_videos.sql}" --database=$db_name
|
||||||
|
|
||||||
|
# # Remove the tmp directory securely
|
||||||
|
# ynh_secure_remove --file="$tmpdir"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
for i in $final_path/config/sql/*.sql ; do ynh_psql_execute_file_as_root --file="$i" --database=$db_name ; done
|
||||||
|
|
||||||
# Remove the tmp directory securely
|
|
||||||
ynh_secure_remove --file="$tmpdir"
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# NGINX CONFIGURATION
|
# NGINX CONFIGURATION
|
||||||
|
|
Loading…
Reference in a new issue