Skip to content

Commit

Permalink
Merge pull request #279 from utilitywarehouse/as-apply-output
Browse files Browse the repository at this point in the history
add support for output upload on PR merge
  • Loading branch information
asiyani authored Oct 15, 2024
2 parents b4f7999 + dbc2d72 commit db6fa32
Show file tree
Hide file tree
Showing 18 changed files with 480 additions and 281 deletions.
8 changes: 4 additions & 4 deletions api/v1beta1/module_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,10 @@ const (
ReasonPlanFailed = "PlanFailed"
ReasonApplyFailed = "ApplyFailed"

ReasonInitialised = "Initialised"
ReasonDriftDetected = "DriftDetected"
ReasonNoDriftDetected = "NoDriftDetected"
ReasonApplied = "Applied"
ReasonInitialised = "Initialised"
ReasonPlanOnlyDriftDetected = "PlanOnlyDriftDetected"
ReasonNoDriftDetected = "NoDriftDetected"
ReasonApplied = "Applied"
)

const (
Expand Down
5 changes: 2 additions & 3 deletions git/repos.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,10 @@ import (
// testing the full process of an apply run
// mirror.RepoPool satisfies this interface and drop in replacement
type Repositories interface {
ChangedFiles(ctx context.Context, remote, hash string) ([]string, error)
Clone(ctx context.Context, remote, dst, branch, pathspec string, rmGitDir bool) (string, error)
Hash(ctx context.Context, remote, ref, path string) (string, error)
Mirror(ctx context.Context, remote string) error
ObjectExists(ctx context.Context, remote, obj string) error
Repository(remote string) (*mirror.Repository, error)
Subject(ctx context.Context, remote, hash string) (string, error)
BranchCommits(ctx context.Context, remote, branch string) ([]mirror.CommitInfo, error)
MergeCommits(ctx context.Context, remote, mergeCommitHash string) ([]mirror.CommitInfo, error)
}
58 changes: 22 additions & 36 deletions git/repos_mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

46 changes: 23 additions & 23 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -19,29 +19,29 @@ require (
github.com/redis/go-redis/v9 v9.6.1
github.com/robfig/cron/v3 v3.0.1
github.com/urfave/cli/v2 v2.27.4
github.com/utilitywarehouse/git-mirror v0.2.3
github.com/utilitywarehouse/git-mirror v0.2.4
github.com/utilitywarehouse/go-operational v0.0.0-20220413104526-79ce40a50281
golang.org/x/exp v0.0.0-20240823005443-9b4947da3948
golang.org/x/exp v0.0.0-20241009180824-f66d83c29e7c
golang.org/x/oauth2 v0.23.0
golang.org/x/time v0.6.0
golang.org/x/time v0.7.0
gopkg.in/yaml.v2 v2.4.0
k8s.io/api v0.31.1
k8s.io/apimachinery v0.31.1
k8s.io/client-go v0.31.1
k8s.io/klog/v2 v2.130.1
sigs.k8s.io/controller-runtime v0.19.0
sigs.k8s.io/controller-runtime/tools/setup-envtest v0.0.0-20240820183333-e6c3d139d2b6
sigs.k8s.io/controller-tools v0.16.3
sigs.k8s.io/controller-runtime/tools/setup-envtest v0.0.0-20241011141221-469837099f73
sigs.k8s.io/controller-tools v0.16.4
)

require (
github.com/ProtonMail/go-crypto v1.1.0-alpha.5-proton // indirect
github.com/ProtonMail/go-crypto v1.1.0-beta.0-proton // indirect
github.com/apparentlymart/go-textseg/v15 v15.0.0 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/cenkalti/backoff/v4 v4.3.0 // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/cloudflare/circl v1.4.0 // indirect
github.com/cpuguy83/go-md2man/v2 v2.0.4 // indirect
github.com/cloudflare/circl v1.5.0 // indirect
github.com/cpuguy83/go-md2man/v2 v2.0.5 // indirect
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
github.com/emicklei/go-restful/v3 v3.12.1 // indirect
Expand All @@ -56,7 +56,7 @@ require (
github.com/go-openapi/jsonreference v0.21.0 // indirect
github.com/go-openapi/swag v0.23.0 // indirect
github.com/go-task/slim-sprig/v3 v3.0.0 // indirect
github.com/gobuffalo/flect v1.0.2 // indirect
github.com/gobuffalo/flect v1.0.3 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.4 // indirect
Expand All @@ -71,14 +71,14 @@ require (
github.com/hashicorp/go-rootcerts v1.0.2 // indirect
github.com/hashicorp/go-secure-stdlib/parseutil v0.1.8 // indirect
github.com/hashicorp/go-secure-stdlib/strutil v0.1.2 // indirect
github.com/hashicorp/go-sockaddr v1.0.6 // indirect
github.com/hashicorp/go-sockaddr v1.0.7 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
github.com/hashicorp/terraform-json v0.22.1 // indirect
github.com/imdario/mergo v0.3.16 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/klauspost/compress v1.17.9 // indirect
github.com/klauspost/compress v1.17.11 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/mattn/go-colorable v0.1.13 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
Expand All @@ -90,7 +90,7 @@ require (
github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/prometheus/client_model v0.6.1 // indirect
github.com/prometheus/common v0.55.0 // indirect
github.com/prometheus/common v0.60.0 // indirect
github.com/prometheus/procfs v0.15.1 // indirect
github.com/russross/blackfriday/v2 v2.1.0 // indirect
github.com/ryanuber/go-glob v1.0.0 // indirect
Expand All @@ -103,23 +103,23 @@ require (
github.com/zclconf/go-cty v1.15.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
go.uber.org/zap v1.27.0 // indirect
golang.org/x/crypto v0.26.0 // indirect
golang.org/x/crypto v0.28.0 // indirect
golang.org/x/mod v0.21.0 // indirect
golang.org/x/net v0.28.0 // indirect
golang.org/x/net v0.30.0 // indirect
golang.org/x/sync v0.8.0 // indirect
golang.org/x/sys v0.24.0 // indirect
golang.org/x/term v0.23.0 // indirect
golang.org/x/text v0.17.0 // indirect
golang.org/x/tools v0.24.0 // indirect
golang.org/x/sys v0.26.0 // indirect
golang.org/x/term v0.25.0 // indirect
golang.org/x/text v0.19.0 // indirect
golang.org/x/tools v0.26.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
google.golang.org/protobuf v1.34.2 // indirect
google.golang.org/protobuf v1.35.1 // indirect
gopkg.in/evanphx/json-patch.v4 v4.12.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/apiextensions-apiserver v0.31.0 // indirect
k8s.io/kube-openapi v0.0.0-20240822171749-76de80e0abd9 // indirect
k8s.io/utils v0.0.0-20240821151609-f90d01438635 // indirect
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
k8s.io/apiextensions-apiserver v0.31.1 // indirect
k8s.io/kube-openapi v0.0.0-20241009091222-67ed5848f094 // indirect
k8s.io/utils v0.0.0-20240921022957-49e7df575cb6 // indirect
sigs.k8s.io/json v0.0.0-20241010143419-9aa6b5e7a4b3 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
sigs.k8s.io/yaml v1.4.0 // indirect
)
Loading

0 comments on commit db6fa32

Please sign in to comment.