[REFERENCE ONLY] feat(migrate): full CI migration — all 7 systems (split into stacked PRs)#217
[REFERENCE ONLY] feat(migrate): full CI migration — all 7 systems (split into stacked PRs)#217Viktor (tiulpin) wants to merge 1 commit into
Conversation
42e7c81 to
91a61ac
Compare
54e2b15 to
0cdf2a3
Compare
f1ba219 to
822797b
Compare
822797b to
8dca7af
Compare
8dca7af to
535f44a
Compare
fb9d663 to
78fdeea
Compare
fd684b2 to
18fd8fa
Compare
0da3538 to
ad00b62
Compare
0e45bed to
8753f2d
Compare
087bfdf to
aa7d148
Compare
aa7d148 to
03783e4
Compare
6dad42c to
09175ae
Compare
09175ae to
7c9566d
Compare
7c9566d to
de7c151
Compare
de7c151 to
30981e0
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 58b7b038e9
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "Codex (@codex) review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "Codex (@codex) address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5660d2d40f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "Codex (@codex) review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "Codex (@codex) address that feedback".
| taskSteps, taskCache := convertAzureTask(taskRef, step, stepName, result, opts) | ||
| j.Steps = append(j.Steps, taskSteps...) |
There was a problem hiding this comment.
Preserve step env when converting Azure task steps
buildAzureJob extracts stepEnv for every Azure step, but in the task branch it appends taskSteps directly without attaching those environment variables. This drops env: for common task forms like Bash@3/CmdLine@2/PowerShell@2, so migrated scripts can run without required tokens/flags and fail at runtime even though the source pipeline works.
Useful? React with 👍 / 👎.
| if run, ok := v["run"].(string); ok { | ||
| return []Step{{ScriptContent: mapCircleCIVars(run)}}, false |
There was a problem hiding this comment.
Apply CircleCI parameter substitution to run shorthand
The shorthand run path maps variables but skips substituteCircleParams, so commands written as - run: "echo << parameters.msg >>" keep raw << parameters.* >> placeholders in generated script-content. In parameterized jobs this produces invalid commands after migration; this branch should substitute invocation/job params the same way as the map-form run.command path.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: db5c3b0117
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "Codex (@codex) review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "Codex (@codex) address that feedback".
| if jobsMap, ok := doc["jobs"].(map[string]any); ok { | ||
| if includes, ok := jobsMap["include"].([]any); ok && len(includes) > 0 { | ||
| return convertTravisJobMatrix(doc, includes, result) | ||
| } |
There was a problem hiding this comment.
Keep default Travis jobs when include entries are present
This early return converts only jobs.include/matrix.include entries and skips the base Travis job matrix derived from top-level keys (for example language + node_js/go versions). In common configs where include adds deploy/lint jobs on top of normal build/test jobs, the generated TeamCity pipeline silently drops the primary jobs and can run only the extras.
Useful? React with 👍 / 👎.
| steps, ok := job["steps"].([]any) | ||
| if !ok { | ||
| continue | ||
| } |
There was a problem hiding this comment.
Emit CircleCI jobs even when
steps is omitted
Jobs are skipped entirely when job["steps"] is absent, which drops valid workflow nodes such as type: no-op jobs (or other non-step templates) and leaves downstream dependencies pointing at jobs that were never emitted. This can produce broken execution graphs after migration even though the source CircleCI workflow is valid.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7826181b7d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "Codex (@codex) review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "Codex (@codex) address that feedback".
| if image, ok := doc["image"].(string); ok { | ||
| globalImage = image | ||
| } else if imgMap, ok := doc["image"].(map[string]any); ok { | ||
| if name, ok := imgMap["name"].(string); ok { |
There was a problem hiding this comment.
Handle GitLab
default.image inheritance
The converter only reads doc["image"] for the global runtime image and never inspects default.image, so pipelines that set a shared image under default are migrated without any Docker-image manual setup hint. In those repos, converted jobs can run on agents missing required tooling because the inherited container context is silently dropped.
Useful? React with 👍 / 👎.
| if services, ok := doc["services"].([]any); ok && len(services) > 0 { | ||
| result.ManualSetup = append(result.ManualSetup, | ||
| fmt.Sprintf("Global services %v → configure as Docker Compose or agent-level services", extractGitLabServiceNames(services))) |
There was a problem hiding this comment.
Account for GitLab
default.services
Global service detection only checks top-level services, so default.services is ignored. When a GitLab pipeline defines shared services (e.g., Postgres/Redis) in default, the migration omits the corresponding manual setup guidance and generated jobs run without those service containers, which can break otherwise-valid test/deploy stages.
Useful? React with 👍 / 👎.
…s, 60+ action transformers
Warning
This PR is reference-only — do not merge. It grew too large for a single review pass. The work has been split into focused PRs starting with #226.
Why this PR is no longer active
The original scope (foundation + 7 CI converters + skill + issue template) landed at ~7.3k insertions across 42 files, which is too much to review in one shot. The code is sound and has been through multiple rounds of Codex review and bug fixes, but it needs to land in digestible slices.
Split plan
Each follow-up PR is an independent, self-contained slice against `main`. They'll land sequentially (not stacked) so each can be reviewed against the previous merged state.
Priority / tier rationale (based on JetBrains 2024 Developer Ecosystem survey × our code investment × strategic value for TeamCity): GHA + Jenkins + GitLab together cover ~89% of real-world CI usage.
What this branch still contains
The full 7-system implementation, already refined through:
Follow-up PRs will cherry-pick each CI's code from this branch and add it on top of the foundation.
Next step
Review and merge #226. Once it lands, PR #2 (GitLab) will be cut off fresh `main` using this branch as the source material.