How to create symlink for storage public folder for Lumen

久未见 提交于 2020-04-16 03:27:05

问题


I have used the following command to create symnlink for storage public folder for my project which I'm doing in Lumen . => php artisan storage:link

But I am getting this error in terminal =>

There are no commands defined in the "storage" namespace.

Another query is though I'm able to upload file in storage folder , how I'm able to access, I need some sample code for this. Kindly help.


回答1:


I created by this unix command :

ln -s sourceforwhich symnlinkfolderpath e.g.:

ln -s /data/html/projectfolder/storage/app/public /data/html/projectfolder/public/storage




回答2:


Lumen's artisan doesn't support "storage", that's why you got an error. Try to upload your file to app/public folder instead.

Change your upload path to app/public, too.



来源:https://stackoverflow.com/questions/47772360/how-to-create-symlink-for-storage-public-folder-for-lumen

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!