-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
enhancementNew feature or requestNew feature or request
Milestone
Description
Summary
Add CircleCI as a supported DevOps tool in the CLI. CircleCI is a popular cloud CI/CD platform providing build and deployment data for DORA metrics (deployment frequency, change failure rate).
Upstream Plugin
circleci in incubator-devlake/backend/plugins/circleci/
| Property | Value |
|---|---|
| Plugin slug | circleci |
| Auth | AccessToken (custom header: Circle-Token) |
| Scope type | Projects (Id string, includes Slug and OrganizationId) |
| Scope ID field | id |
| Default endpoint | https://circleci.com/api/v2/ |
| Remote-scope API | Yes |
| Connection test | Yes |
Dependencies
Blocked by:
- Generic scope ID extraction and remote-scope API client #86 — Scope ID extraction (needs
ScopeIDField)
Not blocked by #85 — CircleCI uses AccessToken, compatible with current auth model. The custom header format (Circle-Token) is handled by the DevLake backend.
Changes
- Add
ConnectionDefforcircleciinconnectionRegistry:Endpoint: "https://circleci.com/api/v2/"SupportsTest: trueTokenPrompt: "CircleCI personal API token"EnvVarNames: []string{"CIRCLECI_TOKEN", "CIRCLE_TOKEN"}EnvFileKeys: []string{"CIRCLECI_TOKEN", "CIRCLE_TOKEN"}ScopeIDField: "id"ScopeFunc: scopeCircleCIHandler
- Implement
scopeCircleCIHandler:- Use
client.ListRemoteScopes("circleci", connID, "", "")to list projects - Let user select projects interactively
- PUT selected projects as scopes
- Use
- Set
Available: true
Acceptance Criteria
-
gh devlake configure connection add --plugin circlecicreates a CircleCI connection - CircleCI appears in interactive plugin picker
- CircleCI scopes list projects for selection
- Connection test works
-
go build ./...,go test ./...,go vet ./...pass
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request