Skip to main content

How to store resources when doing a clone?

Comments

5 comments

  • cPRex Jurassic Moderator

    Hey hey!  The only way I know of that you can store data outside of public_html would be with manual edits to the configuration as we don't allow that in the cPanel user interface.  This feature is designed to help users deploy their site if it's from a Git repository, so it's not intended to be used for outside development tasks.

    0
  • Monaj Sing

    Hi,

    You’re correct, when you run:

     
    git clone git://git.moodle.org/moodle.git
     

    Git will clone the repository into a new folder (named moodle) inside your current directory.

    If you want to store it in a specific folder (for example, outside public_html)You have two options:

    Option 1: Run clone from the target directory

    Option 2: Specify the full target path directly

     

    0
  • Michael Jordan

    If you want the repository stored outside public_html, you can specify the destination directory when cloning. For example:

    git clone git://git.moodle.org/moodle.git /home/XXX/Source-files/moodle

    That should create the Moodle repository inside the specified folder instead of the current working directory. Just make sure the account has the necessary permissions for that location.

    -1
  • omkar Dalvi

    Yes, you can specify the destination folder directly when cloning the repository. If you want Moodle to be stored outside public_html, use:

    git clone git://git.moodle.org/moodle.git "/home/XXX/Source files/moodle"

    This will create the Moodle repository inside:

    /home/XXX/Source files/moodle

    Since the folder name contains a space, putting the path inside quotes is important. You can then keep your Git/Moodle source files outside public_html and use the appropriate files for your live Moodle installation.

    0
  • Prashant kumar

    i have same issue but your comment section help me

     

    0

Please sign in to leave a comment.