> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ornn.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Pull a GitHub repository into a volume

Pull a branch of a GitHub repository into an Ornn volume. The files are written to a folder on the volume and are available on every node that mounts it.

## Connect a GitHub account

A GitHub connection is yours, in one organization. Set it up once, and it works for every volume you own in that organization.

1. Open **Account** and select the **GitHub** tab.
2. Click **Connect GitHub**.
3. Approve Ornn on GitHub. If the Ornn app is not installed on any account yet, GitHub also asks to install it. Choose the account and the repositories Ornn may read.
4. GitHub returns to the **GitHub** tab, which lists the connected accounts.

To connect another personal account or organization, click **Add account**. GitHub opens in a new tab, and the list updates when the install is complete.

Each connected account has two actions:

* **Manage on GitHub** opens the app's installation settings on GitHub. Use it to change which repositories Ornn can read, or to uninstall the app.
* **Disconnect** removes the account from Ornn. The app stays installed on GitHub, so **Connect GitHub** restores the account in one step.

An account whose app is uninstalled on GitHub is removed from the list automatically.

<Note>
  Ornn reads only the repositories selected in the installation and never writes to GitHub. To add a
  repository, change the installation on GitHub.
</Note>

## Pull a repository into a volume

1. In **Storage**, open a volume, or open a mounted volume from the reservation **Volume** tab.
2. Click **Pull from GitHub**.
3. Select a repository and a branch. The default branch is preselected.
4. Keep the folder name or enter a new one. The default is the repository name.
5. Click **Pull repository**.

A progress panel shows each step: **Checking branch**, **Downloading repository**, **Writing files**, and **Finishing up**. On completion, the files are in `<folder>/` on the volume.

A volume can hold several repositories, each in its own folder, alongside uploaded files. The target folder must not already contain files; a pull into such a folder is refused, so existing files are never overwritten.

## Create a volume from a repository

1. In **Storage**, click **Create Ornn bucket**.
2. Select **From a GitHub repository**.
3. Select the repository, branch, and folder. The bucket name defaults to the repository name.
4. Click **Create and pull**.

If the pull fails, the new volume is deleted.

## When files reach the nodes

Availability depends on the volume:

| Volume                                  | Result                                                                                                                                                                  |
| --------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Mounted                                 | Nodes see the new folder within seconds. No remount is needed.                                                                                                          |
| Ornn bucket, not deployed               | Files stay in the volume and are copied on the next deploy.                                                                                                             |
| Connected AWS S3 or Google Cloud bucket | Deploy the bucket once first, so Ornn can create its working copy. **Pull from GitHub** is disabled until then.                                                         |
| Copying for a deploy                    | The pull waits for the copy to finish, then starts. If the copy has not started after 5 minutes, the pull stops with an error: deploy the volume again, then try again. |

## Keep a repository up to date

* Click **Sync** next to a repository to pull the latest commit of its branch into the same folder. When the commit has not changed and no repository file is missing, nothing is downloaded. Syncing a mounted volume is safe.
* A sync follows these rules:
  * A file that is new or changed on GitHub is written. If a file already exists at that path, GitHub's version replaces it.
  * A repository file that is missing from the folder is written back, even when GitHub has no new commit. This is true when you delete it in **Storage**, with **Clear files**, or on a node.
  * A file deleted on GitHub is deleted from the folder.
  * A repository file that did not change on GitHub is not touched, even when it was edited on a node.
  * A file created in the folder from a node or an upload, at a path the repository does not use, is kept.
* The folder is a copy of the branch. Changes made on a node or in **Storage** stay on the volume only.
* Keep your own files outside the repository's paths, for example in a separate folder, so a sync never replaces them.
* Deleting the repository's folder does not remove the repository from the volume. It stays listed with its **Sync** button.
* To use a repository on another reservation, detach the volume and deploy it there.

## Limits

* **Files only.** No Git history is pulled, and there is no `.git` folder on the node.
* **1 GiB per pull.** Git LFS files count at their full size. A larger branch is refused. Contact support for a higher limit.
* **Git LFS.** LFS files are pulled as real files, not pointer files. The download counts against the repository owner's Git LFS bandwidth on GitHub. An LFS file that GitHub no longer has is written as its pointer file and reported as skipped.
* **Symbolic links** are kept as links. On a node that mounts the volume, a link works as it does in the repository: `Makefile` opens `build/root/Makefile`, and the target is stored only once. In the file browser, a link shows **Link to** and its target; click it to open the target's folder. A link that points outside the repository, such as `../../etc/passwd`, is skipped.
* **Skipped files.** Files whose names contain a control character, such as a tab, or a backslash are skipped. The repository row shows **N skipped**; click it to see each skipped file and why (link points outside the repository, name not allowed, or LFS file not available). The list shows up to 100 files and stays until a later sync replaces it.
* **Rate limits.** When GitHub rate limits Ornn, the sync waits and retries on its own. After one hour it stops, and the repository shows an error; click **Sync** to try again.
