Skip to content

Commit

Permalink
changed script
Browse files Browse the repository at this point in the history
  • Loading branch information
SaminYaser-work committed Sep 16, 2023
1 parent 93a7be0 commit 4bcbe21
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions startup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ echo "Script started" > /home/site/wwwroot/startup_status.txt

# File upload fix
sed -i 's|abort_unless|//&|g' /home/site/wwwroot/vendor/livewire/livewire/src/Controllers/FileUploadHandler.php
sed -i '/tmpfile/a $tmpfname = tempnam(sys_get_temp_dir(), "");\n$tmpFile = fopen($tmpfname, "w");' /home/site/wwwroot/vendor/livewire/livewire/src/TemporaryUploadedFile.php
sed -i 's/$tmpFile/\/\/&/' /home/site/wwwroot/vendor/livewire/livewire/src/TemporaryUploadedFile.php
#sed -i '/tmpfile/a $tmpfname = tempnam(sys_get_temp_dir(), "");\n$tmpFile = fopen($tmpfname, "w");' /home/site/wwwroot/vendor/livewire/livewire/src/TemporaryUploadedFile.php
#sed -i 's/$tmpFile/\/\/&/' /home/site/wwwroot/vendor/livewire/livewire/src/TemporaryUploadedFile.php
mkdir /home/site/wwwroot/storage/app/public/livewire-tmp
chmod -R 755 /home/site/wwwroot/storage

Expand All @@ -23,4 +23,4 @@ php artisan event:cache
php artisan route:cache
php artisan view:cache

echo "Startup script ran successfully." > /home/site/wwwroot/startup_status.txt
echo "$(date '+%Y-%m-%d %H:%M:%S') Startup script ran successfully." > /home/site/wwwroot/startup_status.txt

0 comments on commit 4bcbe21

Please sign in to comment.