Skip to content

gitops

The gitops domain has 13 actions. On the meta surface they are all reached through arcane_gitops; on the individual surface each one is its own tool; on the dynamic surface run them with arcane_execute_action and the canonical ID.

ActionTitleKind
gitops.backup_historyList Git backup historyread
gitops.backup_previewPreview a Git backupread
gitops.backup_resolve_conflictResolve a Git backup conflictdestructive
gitops.backup_revisionGet a Git backup revisionread
gitops.browse_filesBrowse GitOps sync filesread
gitops.createCreate a GitOps syncwrite
gitops.deleteDelete a GitOps syncdestructive
gitops.getGet a GitOps syncread
gitops.importImport GitOps syncswrite
gitops.listList GitOps syncsread
gitops.statusGet GitOps sync statusread
gitops.syncPerform a GitOps syncdestructive
gitops.updateUpdate a GitOps syncwrite

List Git backup history

List repository revisions that changed the backup

  • Kind: read
  • Required parameters: syncId
  • Meta tool: arcane_gitops with "action": "backup_history"
  • Individual tool: arcane_gitops_backup_history
  • Arcane route: GET /api/environments/{id}/gitops-syncs/{syncId}/backup/history
  • Operation ID: listGitOpsBackupHistory
  • Since: Arcane v2.12.0
  • Usage: Backup syncs only. syncId from gitops.list with mode=backup. Needs gitops:backup. Returns entries, newest first, of the commits on the branch that touched backupDirectory (commit, author, message, date, files relative to backupDirectory). limit defaults to 20, max 200. Pass an entry’s commit to gitops.backup_revision for its diffs.
  • Related actions: gitops.backup_revision, gitops.backup_preview, gitops.list

Preview a Git backup

Show the files the next backup would commit and any conflicts

  • Kind: read
  • Required parameters: syncId
  • Meta tool: arcane_gitops with "action": "backup_preview"
  • Individual tool: arcane_gitops_backup_preview
  • Arcane route: GET /api/environments/{id}/gitops-syncs/{syncId}/backup/preview
  • Operation ID: previewGitOpsBackup
  • Since: Arcane v2.12.0
  • Usage: Backup syncs only (mode=backup, else 400). syncId from gitops.list with mode=backup. Needs gitops:backup. Compares the project’s files with the repository without committing: state clean, changes, conflict (files edited in the repository since the last backup, listed in conflicts) or destination_occupied (backupDirectory already holds files Arcane did not write). changes lists what the next gitops.sync would commit, files the selected paths (.env files are never backed up), remoteCommit the branch head.
  • Related actions: gitops.sync, gitops.backup_resolve_conflict, gitops.backup_history

Resolve a Git backup conflict

Resolve a backup that needs attention

  • Kind: destructive — requires confirm: true
  • Required parameters: syncId, strategy
  • Meta tool: arcane_gitops with "action": "backup_resolve_conflict"
  • Individual tool: arcane_gitops_backup_resolve_conflict
  • Arcane route: POST /api/environments/{id}/gitops-syncs/{syncId}/backup/resolve
  • Operation ID: resolveGitOpsBackupConflict
  • Since: Arcane v2.12.0
  • Usage: strategy=use_arcane overwrites the repository’s backup files with Arcane’s and commits. Check gitops.backup_preview (state conflict) first.
  • Related actions: gitops.backup_preview, gitops.status, gitops.backup_history

Get a Git backup revision

Get one revision with per-file diffs

  • Kind: read
  • Required parameters: syncId, commit
  • Meta tool: arcane_gitops with "action": "backup_revision"
  • Individual tool: arcane_gitops_backup_revision
  • Arcane route: GET /api/environments/{id}/gitops-syncs/{syncId}/backup/history/{commit}
  • Operation ID: getGitOpsBackupRevision
  • Since: Arcane v2.12.0
  • Usage: Backup syncs only. syncId from gitops.list with mode=backup, commit (hex hash) from gitops.backup_history. Needs gitops:backup. Returns entry (commit, author, message, date, files) and diffs with one unified patch per file inside backupDirectory, paths relative to it.
  • Related actions: gitops.backup_history

Browse GitOps sync files

Browse files in the synced repository

  • Kind: read
  • Required parameters: syncId
  • Meta tool: arcane_gitops with "action": "browse_files"
  • Individual tool: arcane_gitops_browse_files
  • Arcane route: GET /api/environments/{id}/gitops-syncs/{syncId}/files
  • Operation ID: browseGitOpsSyncFiles
  • Usage: syncId from gitops.list. Clones the sync’s branch head and lists one directory level (name, path, type file or directory, size). path is relative to the repository root, not to composePath, and defaults to the root. Use it to find the composePath for gitops.update. git_repository.browse_files does the same for any branch before a sync exists.
  • Related actions: gitops.list, gitops.update, git_repository.browse_files

Create a GitOps sync

Create a new GitOps sync configuration for an environment

  • Kind: write
  • Required parameters: branch, name, repositoryId
  • Meta tool: arcane_gitops with "action": "create"
  • Individual tool: arcane_gitops_create
  • Arcane route: POST /api/environments/{id}/gitops-syncs
  • Operation ID: createGitOpsSync
  • Usage: repositoryId from git_repository.list, branch from git_repository.branches. Deploy mode (default) needs composePath and clones and syncs at once, creating the project (projectName, default the sync name), which it starts only when redeployAfterSync is true. syncDirectory defaults to false, so only the compose file (plus a .env and override file beside it) is copied unless it is true. Backup mode (mode=backup, projectId, backupDirectory, optional backupPaths, needs gitops:backup) commits the first backup at once and defaults autoSync to true. On a remote environment push the repository there first with environment.sync.
  • Related actions: git_repository.list, git_repository.branches, gitops.sync, gitops.status, environment.sync

Delete a GitOps sync

Delete a GitOps sync configuration by ID

  • Kind: destructive — requires confirm: true
  • Required parameters: syncId
  • Meta tool: arcane_gitops with "action": "delete"
  • Individual tool: arcane_gitops_delete
  • Arcane route: DELETE /api/environments/{id}/gitops-syncs/{syncId}
  • Operation ID: deleteGitOpsSync
  • Usage: syncId from gitops.list. Stops the scheduled sync and any pending backup and unlinks the project, which stays in place with its containers and files (and becomes editable again). Nothing is removed from the repository. Remove the project with project.destroy if it is no longer wanted. A backup sync needs gitops:backup.
  • Related actions: gitops.list, project.destroy

Get a GitOps sync

Get a GitOps sync by ID

  • Kind: read
  • Required parameters: syncId
  • Meta tool: arcane_gitops with "action": "get"
  • Individual tool: arcane_gitops_get
  • Arcane route: GET /api/environments/{id}/gitops-syncs/{syncId}
  • Operation ID: getGitOpsSync
  • Usage: syncId from gitops.list. Returns the full configuration: repository (with repositoryId), branch, composePath, targetType, projectId/projectName, mode, autoSync and syncInterval (minutes), syncDirectory, pullImageAfterSync, redeployAfterSync, sync limits, pre-deploy hook fields, backup fields (backupDirectory, backupPaths, backupOnSave, backupState) and the last run (lastSyncAt, lastSyncStatus, lastSyncError, lastSyncCommit, syncedFiles). Use it to verify gitops.update.
  • Related actions: gitops.list, gitops.status, gitops.update, project.get

Import GitOps syncs

Import multiple GitOps sync configurations from JSON

  • Kind: write
  • Required parameters: body
  • Meta tool: arcane_gitops with "action": "import"
  • Individual tool: arcane_gitops_import
  • Arcane route: POST /api/environments/{id}/gitops-syncs/import
  • Operation ID: importGitOpsSyncs
  • Usage: Creates syncs in bulk. Each item names its repository by git_repository name (gitRepo), not by URL or ID. Returns successCount, failedCount and errors (one message per failed item). The body is the array of items (syncName, gitRepo, branch, dockerComposePath, autoSync, syncInterval required). Every item becomes a deploy-mode project sync and runs its first sync at once, like gitops.create. An item counts as a success even when that first sync fails, so check lastSyncStatus with gitops.list or gitops.status.
  • Related actions: git_repository.list, gitops.list, gitops.create, gitops.status

List GitOps syncs

Get a paginated list of GitOps syncs for an environment

  • Kind: read
  • Required parameters: none
  • Meta tool: arcane_gitops with "action": "list"
  • Individual tool: arcane_gitops_list
  • Arcane route: GET /api/environments/{id}/gitops-syncs
  • Operation ID: listGitOpsSyncs
  • Usage: The starting point for every syncId: returns a page of the environment’s syncs (id, name, mode deploy or backup, repositoryId, branch, composePath, projectId, autoSync, syncInterval in minutes, lastSyncStatus) plus counts (totalSyncs, activeSyncs = autoSync on, successfulSyncs, deploySyncs, backupSyncs). search matches name, branch, composePath or backupDirectory. Filter with mode, projectId, repositoryId (from git_repository.list) or autoSync=true/false, and paginate with start and limit (default 20).
  • Related actions: gitops.get, gitops.status, gitops.create, git_repository.list

Get GitOps sync status

Get the current status of a GitOps sync

  • Kind: read
  • Required parameters: syncId
  • Meta tool: arcane_gitops with "action": "status"
  • Individual tool: arcane_gitops_status
  • Arcane route: GET /api/environments/{id}/gitops-syncs/{syncId}/status
  • Operation ID: getGitOpsSyncStatus
  • Usage: syncId from gitops.list. A light check after gitops.sync or gitops.create: lastSyncStatus (success, failed, running), lastSyncError, lastSyncCommit, lastSyncAt and nextSyncAt (only when autoSync is on and the sync has run). Backup syncs add backupState (never, pending, backing_up, backed_up, paused, failed, needs_attention), backupPending and backupFailureReason. When gitops.sync returns only a generic failure, the cause is in lastSyncError here.
  • Related actions: gitops.sync, gitops.get, gitops.backup_preview

Perform a GitOps sync

Manually trigger a sync operation

  • Kind: destructive — requires confirm: true
  • Required parameters: syncId
  • Meta tool: arcane_gitops with "action": "sync"
  • Individual tool: arcane_gitops_sync
  • Arcane route: POST /api/environments/{id}/gitops-syncs/{syncId}/sync
  • Operation ID: performGitOpsSync
  • Usage: Runs a sync now: pulls the branch into the project (deploy) or commits the project’s files to the repository (backup). syncId from gitops.list. Runs synchronously: the clone and the file sync have 5 minutes, and a project’s redeploy after them has no limit of its own (a swarm_stack target’s stack deploy runs inside those 5 minutes). A deploy sync whose files changed redeploys the project (rebuilding the images of services with a build section first, like project.redeploy with build=true) if it is running or redeployAfterSync is set, otherwise only pulls images when pullImageAfterSync is set, so a stopped project needs project.up, and a swarm_stack target redeploys its stack on every run. A backup sync needs gitops:backup. Returns success and message (success false with ‘sync already in progress’ when another run holds it). A failed run returns an error, with the cause in gitops.status lastSyncError.
  • Related actions: gitops.list, gitops.status, gitops.backup_preview, project.up

Update a GitOps sync

Update an existing GitOps sync configuration

  • Kind: write
  • Required parameters: syncId
  • Meta tool: arcane_gitops with "action": "update"
  • Individual tool: arcane_gitops_update
  • Arcane route: PUT /api/environments/{id}/gitops-syncs/{syncId}
  • Operation ID: updateGitOpsSync
  • Usage: syncId from gitops.list. Only the fields sent change (the rest keep their value). mode and backupDirectory cannot be changed. Deploy syncs reject backupPaths and backupOnSave. Backup syncs reject composePath, projectName and deploy options such as syncDirectory=true or redeployAfterSync=true. Changing branch or composePath does not sync by itself (run gitops.sync), but turning autoSync on runs one at once. Pre-deploy hook fields need gitops:lifecycle and the lifecycleEnabled setting, and editing a backup sync needs gitops:backup.
  • Related actions: gitops.get, gitops.sync, gitops.list