gitness icon indicating copy to clipboard operation
gitness copied to clipboard

RFC for new badge type: deployments

Open desktophero opened this issue 6 years ago • 1 comments

Idea

Add a badge type of deployments to consume the deployment status from Drone CI

Use Case

We're using deployments more and more. The current badge status approach is limited to type build and a query for branch. Exposing a badge of deployment would allow endpoints to consume and present a visualization of status for deployment x.

Possible Approach

The interface would be similar to the existing structure:

Status Type Filter Example
Current Branch N/A https://host/api/badges/org/repo/status.svg
Current Branch branch=foo https://host/api/badges/org/repo/status.svg?branch=foo
New Deployment deployment=bar https://host/api/badges/org/repo/status.svg?deployment=foo

Effort

The idea would be to refactor badges.go to allow deployments as a badge type.

Thoughts?

desktophero avatar May 03 '18 18:05 desktophero

Rather than using a special logic for deployment, having a badge for each build step would be sufficient.

pipeline:
  build:
  deploy:
  extra:

Getting a badge via https://host/api/badges/org/repo/status.svg?step=[deploy|build|extra]&branch=... would be great.

PatWie avatar Aug 03 '18 15:08 PatWie