docs: update GitLab integration to use GitLab Duo provider
Replace Anthropic provider with native GitLab Duo integration:
- Configure GitLab Duo provider with CI_JOB_TOKEN authentication
- Add @gitlab/opencode-gitlab-plugin for GitLab API tools
- Remove all custom CI/CD variables (ANTHROPIC_API_KEY, GITLAB_HOST, GITLAB_TOKEN_OPENCODE)
- Use GitLab predefined variables (CI_JOB_TOKEN, CI_SERVER_HOST, CI_PROJECT_PATH)
- Remove glab CLI dependency - plugin provides direct API access
- Add 'Using GitLab Tools' section with practical examples
- Update documentation link to opencode-gitlab-plugin
- Simplify setup - zero custom configuration required
The configuration now uses only GitLab's built-in CI/CD variables and provides native integration with GitLab Duo for AI-powered assistance.
The following comment was made by an LLM, it may be inaccurate:
No duplicate PRs found
cc: @nagyv Hi Viktor 👋 Don't you mind reviewing this? This is related to my recent PR: https://github.com/anomalyco/opencode/pull/7333
lgtm but if yall have ur own process ill wait for Viktor to approve as well
@rekram1-node I would double check with @nagyv before the merge, since it was his contribution. :)
@vglafirov While I understand that GitLab would like to push its GitLab Duo models and I think #7333 is a great addition to OpenCode, I consider this documentation change a step back to everyone who is not a GitLab Duo subscriber.
My recommendation: write the documentation so that both GitLab Duo users and non-users can use it. Thus the instructions should work not be exclusionary. More specifics in separate comments.
Btw, is my understanding correct that with #7333 merged,
once a GITLAB_TOKEN (possible =CI_JOB_TOKEN) env is set:
- @gitlab/[email protected] - Provider implementation - need GitLab Duo subscription
- @gitlab/[email protected] - OAuth/PAT authentication - valuable only if used with @gitlab/gitlab-ai-provider
- @gitlab/[email protected] - GitLab API tools - the GITLAB_TOKEN will work for tool calls even if I don't use a Duo model (but go directly to Anthropic)
Thus except for the model selection the value of #7333 works without a GitLab Duo subscription too. Is this correct?