Projects
Git Connections

Set the directory a project builds from

Changed on

Changes only the root directory, leaving the repository and production branch alone. Unlike PUT /projects/{id}/git-connection, this accepts a project access token, so CI or an agent can move a project within its repository without being able to change the repository.

The directory is a path relative to the repository root. An empty string, . or / means the repository root. The response carries it in the form a deploy reads it: ./apps/web/ comes back as apps/web.

put/projects/{id}/git-connection/root-directory

Request

  • Base URL
    https://api.volcano.dev
  • Auth
    • HTTP bearer
    • or HTTP bearer

Path parameters

id, string uuid required

Project ID

Request body

SetProjectGitRootDirectoryRequest required
root_directory, string required

Monorepo subdirectory the project builds from, relative to the repository root. An empty string means the repository root.

Response

The project's repo connection, with the new root directory

ProjectGitConnection required
repo_installation_id, integer required
repo_id, integer required

Stable GitHub repository id (repository.id), the authoritative binding.

repo_full_name, string required
root_directory, string required
production_branch, string required

The branch a push must land on to deploy. Follows the repository's GitHub default branch unless the project set its own, which a default-branch rename on GitHub then leaves alone.

updated_at, string date-time required

When the connection last changed: its repository, root directory or production branch. Naming the branch it already uses, and other changes to the project, leave it alone. A connection that has not changed since Volcano began tracking this reports the project's last change before then.

Changes