-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add filter: ignore if unmanaged by release-manager (#17)
* Add filter: ignore if unmanaged by release-manager * Update go.mod Co-authored-by: Bjørn <[email protected]> Co-authored-by: Bjørn <[email protected]>
- Loading branch information
1 parent
1b51a91
commit b8ff972
Showing
4 changed files
with
130 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
package main | ||
|
||
import "time" | ||
|
||
// Would be nice to be able to do, instead of this: | ||
// httpinternal "github.com/lunarway/release-manager/internal/http" | ||
|
||
// Policy | ||
type ListPoliciesResponse struct { | ||
Service string `json:"service,omitempty"` | ||
AutoReleases []AutoReleasePolicy `json:"autoReleases,omitempty"` | ||
BranchRestrictions []BranchRestrictionPolicy `json:"branchRestrictions,omitempty"` | ||
} | ||
|
||
type AutoReleasePolicy struct { | ||
ID string `json:"id,omitempty"` | ||
Branch string `json:"branch,omitempty"` | ||
Environment string `json:"environment,omitempty"` | ||
} | ||
|
||
type BranchRestrictionPolicy struct { | ||
ID string `json:"id,omitempty"` | ||
Environment string `json:"environment,omitempty"` | ||
BranchRegex string `json:"branchRegex,omitempty"` | ||
} | ||
|
||
// describeArtifact | ||
type DescribeArtifactResponse struct { | ||
Service string `json:"service,omitempty"` | ||
Artifacts []Spec `json:"artifacts,omitempty"` | ||
} | ||
|
||
type Spec struct { | ||
ID string `json:"id,omitempty"` | ||
Service string `json:"service,omitempty"` | ||
Namespace string `json:"namespace,omitempty"` | ||
Application Repository `json:"application,omitempty"` | ||
CI CI `json:"ci,omitempty"` | ||
Squad string `json:"squad,omitempty"` | ||
Shuttle Shuttle `json:"shuttle,omitempty"` | ||
Stages []Stage `json:"stages,omitempty"` | ||
} | ||
|
||
type Repository struct { | ||
Branch string `json:"branch,omitempty"` | ||
SHA string `json:"sha,omitempty"` | ||
AuthorName string `json:"authorName,omitempty"` | ||
AuthorEmail string `json:"authorEmail,omitempty"` | ||
CommitterName string `json:"committerName,omitempty"` | ||
CommitterEmail string `json:"committerEmail,omitempty"` | ||
Message string `json:"message,omitempty"` | ||
Name string `json:"name,omitempty"` | ||
URL string `json:"url,omitempty"` | ||
Provider string `json:"provider,omitempty"` | ||
} | ||
|
||
type Shuttle struct { | ||
Plan Repository `json:"plan,omitempty"` | ||
ShuttleVersion string `json:"shuttleVersion,omitempty"` | ||
} | ||
|
||
type CI struct { | ||
JobURL string `json:"jobUrl,omitempty"` | ||
Start time.Time `json:"start,omitempty"` | ||
End time.Time `json:"end,omitempty"` | ||
} | ||
|
||
type Stage struct { | ||
ID string `json:"id,omitempty"` | ||
Name string `json:"name,omitempty"` | ||
Data interface{} `json:"data,omitempty"` | ||
} |