fix: Command failed: git pull fatal: detected dubious o

This commit fixes an exception detected by OneUptime.

Exception Type: 128
Exception ID: 57441092-d4b7-4ed1-b275-2426a5c9a906

Automatically generated by OneUptime AI Agent.
This commit is contained in:
OneUptime AI Agent
2026-01-08 13:27:26 +00:00
parent 8826635920
commit 7b466679e4
2 changed files with 17 additions and 0 deletions

View File

@@ -75,6 +75,15 @@ export default class CodeRepositoryUtil {
@CaptureSpan()
public static async pullChanges(data: { repoPath: string }): Promise<void> {
// Add the repository to safe.directory to avoid "dubious ownership" errors
// This is needed when running in containers where the repo may be owned by a different user
await this.runGitCommand(data.repoPath, [
"config",
"--global",
"--add",
"safe.directory",
path.resolve(data.repoPath),
]);
await this.runGitCommand(data.repoPath, ["pull"]);
}

8
opencode.json Normal file
View File

@@ -0,0 +1,8 @@
{
"enabled_providers": [
"anthropic"
],
"model": "anthropic/claude-opus-4-5",
"small_model": "anthropic/claude-haiku-4-20250514",
"$schema": "https://opencode.ai/config.json"
}