Track environment deploy through API
Problem to solve
Environment API do not allow to trigger deploy.
Intended users
This feature is mainly for Developers, but may interest Release Managers.
Further details
In the company work for, the deployment is performed using capistrano. But, for the moment, we are not able to include this step to a Gitlab CI job.
Still, I really want to use Gitlab Environment as a "what is deployed" tracker for my teams and my customers.
Proposal
Add API entry point(s) to trigger deployments.
The API should allow the same thing that Gitlab CI "environment" does. See https://docs.gitlab.com/ee/ci/yaml/README.html#environment
Permissions and Security
I believe that if you are allowed to create environment through the API, you should be allowed to track deployment too.
Documentation
The documentation should explain what a client can do with these new APIs. New routes, input & output payload should be detailled. Examples should be provided, and maybe screenshot can be added to illustate everything.
What does success look like, and how can we measure that?
Doing this will prevent developers to introduce some tricks in their pipeline just to avoid triggering the whole pipeline for a simple commit update in an environment.
Links / references
- Gitlab Environment API doc : https://docs.gitlab.com/ee/api/environments.html
- Gitlab CI Environment doc : https://docs.gitlab.com/ee/ci/yaml/README.html#environment