Laravel Creating symbolic link in a web server using SSH


Example

In Laravel documentation, a symbolic link (symlink or soft link) from public/storage to storage/app/public should be created to make files accessible from the web.

(THIS PROCEDURE WILL CREATE SYMBOLIC LINK WITHIN THE LARAVEL PROJECT DIRECTORY)

Here are the steps on how you can create symbolic link in your Linux web server using SSH client:

  1. Connect and login to your web server using SSH client (e.g. PUTTY).

  2. Link storage/app/public to public/storage using the syntax

    ln -s target_path link_path

    Example (in CPanel File Directory)

    ln -s /home/cpanel_username/project_name/storage/app/public /home/cpanel_sername/project_name/public/storage

(A folder named storage will be created to link path with an indicator >>> on the folder icon.)