fix(git-sync): run auto-pull as the admin who enabled it (#11121)

* fix(git-sync): run auto-pull as the admin who enabled it

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

* fix(git-sync): audit the admin grant fork pulls make

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

* chore: bump ee ref for the post-commit fork grant audit

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

* fix(git-sync): address review nits on the auto-pull stamp

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

* chore: update ee-repo-ref to ccada062c072d7b74894b63863728fd1ef9bdffd

This commit updates the EE repository reference after PR #799 was merged in windmill-ee-private.

Previous ee-repo-ref: 7cee30f0cf12721cba551cd754dc817444810470

New ee-repo-ref: ccada062c072d7b74894b63863728fd1ef9bdffd

Automated by sync-ee-ref workflow.

---------

Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
Co-authored-by: windmill-internal-app[bot] <windmill-internal-app[bot]@users.noreply.github.com>
This commit is contained in:
hugocasa
2026-09-15 10:34:57 +02:00
committed by GitHub
co-authored by Claude Opus 5 windmill-internal-app[bot]
parent 082d897328
commit 69e6efd875
20 changed files with 481 additions and 43 deletions
@@ -1,5 +1,5 @@
import { getContext, setContext } from 'svelte'
import { enterpriseLicense } from '$lib/stores'
import { enterpriseLicense, userStore } from '$lib/stores'
import { get } from 'svelte/store'
import { sendUserToast } from '$lib/toast'
import { apiErrorMessage } from '$lib/utils'
@@ -534,6 +534,15 @@ export function createGitSyncContext(workspace: string) {
}
})
// The server stamps the saving admin as who pulls run as; mirror it so the card
// names them without a reload.
if (repoToSave.auto_pull) {
repoToSave.auto_pull = {
...repoToSave.auto_pull,
enabled_by: repoToSave.auto_pull.enabled ? get(userStore)?.email : undefined
}
}
// Update local state with migrated repository
repositories[idx] = repoToSave
initialRepositories[idx] = { ...repoToSave }
@@ -1038,6 +1038,14 @@
: 'Checking the tracked branch about every minute. New commits deploy automatically.'}
{/if}
</div>
{#if repo.auto_pull?.enabled_by}
<div class="text-2xs text-secondary mt-1">
Pulls apply changes as {repo.auto_pull.enabled_by}, the admin who last saved
these settings{repo.auto_pull.sync_forks
? ', in this workspace and its forks'
: ''}.
</div>
{/if}
{#if hasManagedCredential && repo.auto_pull?.webhook_error}
<div class="mt-2">
<Alert type="warning" title="Falling back to polling" size="xs">