Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support azure devops repos #194

Merged
merged 2 commits into from
Jul 16, 2024
Merged

Support azure devops repos #194

merged 2 commits into from
Jul 16, 2024

Conversation

aclevername
Copy link
Member

@aclevername aclevername commented Jul 12, 2024

Searching for the error came up with a lot of results for this issue when using go-git https://www.google.com/search?q=unexpected+client+error+400+devops+git+clone&oq=unexpected+client+error+400+devops+git+clone&gs_lcrp=EgZjaHJvbWUyBggAEEUYOTIHCAEQIRigATIHCAIQIRigATIHCAMQIRigAdIBCDU0MzdqMGo3qAIAsAIA&sourceid=chrome&ie=UTF-8

Found the fix here pulumi/pulumi#12001. Original issue in go-git go-git/go-git#64

before:

2024-07-12T16:43:25Z    INFO    controllers.DestinationController.writers.GitStateStoreWriter   creating local directory        {"destination": {"name":"worker"}, "dir": "worker", "branch": "main"}
2024-07-12T16:43:25Z    INFO    controllers.DestinationController.writers.GitStateStoreWriter   cloning repo    {"destination": {"name":"worker"}, "dir": "worker", "branch": "main"}
2024-07-12T16:43:27Z    ERROR   controllers.DestinationController.writers.GitStateStoreWriter   could not clone repository      {"destination": {"name":"worker"}, "dir": "worker", "branch": "main", "error": "unexpected client error: unexpected requesting \"https://dev.azure.com/syntasso/jake/_git/jake/git-upload-pack\" status code: 400"}
github.com/syntasso/kratix/lib/writers.(*GitWriter).setupLocalDirectoryWithRepo
        /workspace/lib/writers/git.go:242
github.com/syntasso/kratix/lib/writers.(*GitWriter).update
        /workspace/lib/writers/git.go:122
github.com/syntasso/kratix/lib/writers.(*GitWriter).UpdateFiles
        /workspace/lib/writers/git.go:108
github.com/syntasso/kratix/controllers.(*DestinationReconciler).createDependenciesPathWithExample
        /workspace/controllers/destination_controller.go:135
github.com/syntasso/kratix/controllers.(*DestinationReconciler).Reconcile
        /workspace/controllers/destination_controller.go:84
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Reconcile
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.18.4/pkg/internal/controller/controller.go:114
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).reconcileHandler
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.18.4/pkg/internal/controller/controller.go:311
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).processNextWorkItem
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.18.4/pkg/internal/controller/controller.go:261
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func2.2
        /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.18.4/pkg/internal/controller/controller.go:222

after:

2024-07-12T16:37:56Z    INFO    controllers.DestinationController       Registering Destination {"destination": {"name":"worker"}, "requestName": "worker"}
2024-07-12T16:37:57Z    INFO    controllers.DestinationController.writers.GitStateStoreWriter   creating local directory        {"destination": {"name":"worker"}, "dir": "worker", "branch": "main"}
2024-07-12T16:37:57Z    INFO    controllers.DestinationController.writers.GitStateStoreWriter   cloning repo    {"destination": {"name":"worker"}, "dir": "worker", "branch": "main"}
2024-07-12T16:37:57Z    INFO    controllers.DestinationController.writers.GitStateStoreWriter   pushing changes {"destination": {"name":"worker"}, "dir": "worker", "branch": "main"}
2024-07-12T16:37:58Z    INFO    controllers.DestinationController.writers.GitStateStoreWriter   creating local directory        {"destination": {"name":"worker"}, "dir": "worker", "branch": "main"}
2024-07-12T16:37:58Z    INFO    controllers.DestinationController.writers.GitStateStoreWriter   cloning repo    {"destination": {"name":"worker"}, "dir": "worker", "branch": "main"}
2024-07-12T16:37:58Z    INFO    controllers.DestinationController.writers.GitStateStoreWriter   pushing changes {"destination": {"name":"worker"}, "dir": "worker", "branch": "main"}

@aclevername aclevername marked this pull request as ready for review July 12, 2024 16:44
lib/writers/git.go Outdated Show resolved Hide resolved
@aclevername aclevername merged commit e92dadc into main Jul 16, 2024
6 checks passed
@aclevername aclevername deleted the azure-devops branch July 16, 2024 13:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants