1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/chatgpt-web_ynh.git synced 2024-09-03 18:16:21 +02:00

hardcode api_key

This commit is contained in:
Gredin67 2024-03-08 21:06:14 +01:00 committed by GitHub
parent 4695add425
commit 63bb33d060
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -26,6 +26,11 @@ ynh_script_progression --message="Setting up source files..." --weight=1
# Download, check integrity, uncompress and patch the source from app.src # Download, check integrity, uncompress and patch the source from app.src
ynh_setup_source --dest_dir="$install_dir" ynh_setup_source --dest_dir="$install_dir"
if [ $api_key != "" ]
then
ynh_replace_string --match_string="$: apiKey = $apiKeyStorage" --replace_string='$: apiKey = $apiKeyStorage'/n'setOpenAI({apiKey : "'$api_key'"})'/n --target_file=$install_dir/src/lib/Home.svelte
fi
chown -R $app:www-data "$install_dir" chown -R $app:www-data "$install_dir"
#================================================= #=================================================