Skip to content

Commit

Permalink
chore(dep): updates
Browse files Browse the repository at this point in the history
  • Loading branch information
morlay committed Oct 31, 2024
1 parent 15d723d commit bcde5c1
Show file tree
Hide file tree
Showing 8 changed files with 50 additions and 16 deletions.
8 changes: 5 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ module github.com/octohelm/crkit

go 1.23.2

replace github.com/octohelm/courier => ../../../github.com/octohelm/courier

require (
github.com/containerd/containerd v1.7.23
github.com/containerd/platforms v0.2.1
Expand All @@ -12,11 +14,11 @@ require (
github.com/google/go-containerregistry v0.20.2
github.com/google/uuid v1.6.0
github.com/innoai-tech/infra v0.0.0-20241022104251-5a2bfc2c17f7
github.com/octohelm/courier v0.0.0-20241022023800-691a2df64fa6
github.com/octohelm/gengo v0.0.0-20241021060200-490be2d0c7f4
github.com/octohelm/courier v0.0.0-20241031023208-9bf52e91cc01
github.com/octohelm/gengo v0.0.0-20241023040556-a66fecda6cd6
github.com/octohelm/kubekit v0.0.0-20241021071650-ce12d81a1113
github.com/octohelm/kubepkgspec v0.0.0-20241015012541-484a91b9d42a
github.com/octohelm/storage v0.0.0-20241014040055-4f454a8d6947
github.com/octohelm/storage v0.0.0-20241025090738-73beed467466
github.com/octohelm/unifs v0.0.0-20241019063356-9efed187f510
github.com/octohelm/x v0.0.0-20241011014327-0fcf864c84d6
github.com/opencontainers/go-digest v1.0.0
Expand Down
10 changes: 4 additions & 6 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -178,16 +178,14 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G
github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA=
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
github.com/octohelm/courier v0.0.0-20241022023800-691a2df64fa6 h1:AN5L3B8mKNxq7UgmsxYkWajtbz6hNlZx5ZR95AiDCTw=
github.com/octohelm/courier v0.0.0-20241022023800-691a2df64fa6/go.mod h1:ku3NZRmMnvxvbcI5y4AuiaoT4cQOy6KAPiFUiDPc+xk=
github.com/octohelm/gengo v0.0.0-20241021060200-490be2d0c7f4 h1:zd0FrKYk+2aFBbS90nzdXhSpJadMwfZBb9hSamuLEVQ=
github.com/octohelm/gengo v0.0.0-20241021060200-490be2d0c7f4/go.mod h1:7bkbdNmnQEmnVbvdSJdRwvGmm2/3KgvxXSDi/nXCOk8=
github.com/octohelm/gengo v0.0.0-20241023040556-a66fecda6cd6 h1:xsDe0CBcK1CW+dcQdH5mQuVBBScQ1vDbh+cYpVDI7AQ=
github.com/octohelm/gengo v0.0.0-20241023040556-a66fecda6cd6/go.mod h1:aviWG2Mi3alkrLA0G/UtypdM05btKHuLTabGkEmzjWI=
github.com/octohelm/kubekit v0.0.0-20241021071650-ce12d81a1113 h1:TmCl64+TvKbmbvQLYyHazwOOPtAENIo8BitxhW3jFmM=
github.com/octohelm/kubekit v0.0.0-20241021071650-ce12d81a1113/go.mod h1:+DqDRoRFbbZqxTF2nyHhSyDVbqn/8R1/5Ok6RYxpy1A=
github.com/octohelm/kubepkgspec v0.0.0-20241015012541-484a91b9d42a h1:2sAjkSoVexPmR6yPfPk8p2fK4kEajzf7INlXPOlodsc=
github.com/octohelm/kubepkgspec v0.0.0-20241015012541-484a91b9d42a/go.mod h1:tfKjYcUqh4jjnYNbc6nmqA6hKozWwnyxov8sAyFpRCo=
github.com/octohelm/storage v0.0.0-20241014040055-4f454a8d6947 h1:NrKmBgKHtl0FK3RZMZ9x9Epm6ZYnd97SOhjne46pfQY=
github.com/octohelm/storage v0.0.0-20241014040055-4f454a8d6947/go.mod h1:DfC1lOuB05GgCIdqLIOJ6+A4XPtDUkIKKUXqjKxXTNs=
github.com/octohelm/storage v0.0.0-20241025090738-73beed467466 h1:ou9FbRki/qOmh4ABjJrdxoVdstfghptoLrCqvTFyYyI=
github.com/octohelm/storage v0.0.0-20241025090738-73beed467466/go.mod h1:8uLIeGCM1mDxEYkS1D88yJa+LC+wPsTtMR2ZAbQf+WA=
github.com/octohelm/unifs v0.0.0-20241019063356-9efed187f510 h1:4UOLgOcyi7Gc2xnrxv2O3RQomwTbnpeKixXVyUQ89h4=
github.com/octohelm/unifs v0.0.0-20241019063356-9efed187f510/go.mod h1:ZVBxTPNTWBAhrJGHP1/jKYw2diQx8e+KE5n9q+kV6IA=
github.com/octohelm/x v0.0.0-20241011014327-0fcf864c84d6 h1:4royPn66/B49ftj5Jh7ZWuJ8A2B/2l0UTQ6EFLf29Vk=
Expand Down
8 changes: 6 additions & 2 deletions pkg/containerdhost/controller/reconciler.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,15 @@ import (

type Reconciler struct {
ConfigPath string `flags:",omitempty"`
mgr controllerruntime.Manager

mgr controllerruntime.Manager
}

func (r *Reconciler) Run(ctx context.Context) error {
return operator.ReconcilerRegistryContext.From(ctx).RegisterReconciler(r)
if x, ok := operator.ReconcilerRegistryFromContext(ctx); ok {
return x.RegisterReconciler(r)
}
return nil
}

func (r *Reconciler) AddToScheme(s *runtime.Scheme) error {
Expand Down
1 change: 1 addition & 0 deletions pkg/content/api/zz_generated.injectable.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import (
)

func (p *NamespaceProvider) InjectContext(ctx context.Context) context.Context {

return content.NamespaceInjectContext(ctx, p)
}

Expand Down
4 changes: 4 additions & 0 deletions pkg/kubepkg/packer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"io"
"net/http/httptest"
"os"
"path/filepath"
"testing"

"github.com/google/go-containerregistry/pkg/name"
Expand Down Expand Up @@ -227,6 +228,9 @@ func Test(t *testing.T) {
}

func writeAsOciTar(filename string, idx v1.ImageIndex) error {
if err := os.MkdirAll(filepath.Dir(filename), os.ModePerm); err != nil {
return err
}
f, err := os.OpenFile(filename, os.O_TRUNC|os.O_WRONLY|os.O_CREATE, 0o600)
if err != nil {
return err
Expand Down
10 changes: 5 additions & 5 deletions pkg/registryhttp/apis/registry/zz_generated.injectable.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ func (v *CancelUploadBlob) Init(ctx context.Context) error {
if value, ok := uploadcache.UploadCacheFromContext(ctx); ok {
v.uploadCache = value
} else {
return fmt.Errorf("missing provider %T", v.uploadCache)
return fmt.Errorf("missing provider %T.uploadCache", v)
}

if err := v.NameScoped.Init(ctx); err != nil {
Expand All @@ -30,7 +30,7 @@ func (v *NameScoped) Init(ctx context.Context) error {
if value, ok := content.NamespaceFromContext(ctx); ok {
v.namespace = value
} else {
return fmt.Errorf("missing provider %T", v.namespace)
return fmt.Errorf("missing provider %T.namespace", v)
}

return nil
Expand All @@ -40,7 +40,7 @@ func (v *UploadBlob) Init(ctx context.Context) error {
if value, ok := uploadcache.UploadCacheFromContext(ctx); ok {
v.uploadCache = value
} else {
return fmt.Errorf("missing provider %T", v.uploadCache)
return fmt.Errorf("missing provider %T.uploadCache", v)
}

if err := v.NameScoped.Init(ctx); err != nil {
Expand All @@ -54,7 +54,7 @@ func (v *UploadPatchBlob) Init(ctx context.Context) error {
if value, ok := uploadcache.UploadCacheFromContext(ctx); ok {
v.uploadCache = value
} else {
return fmt.Errorf("missing provider %T", v.uploadCache)
return fmt.Errorf("missing provider %T.uploadCache", v)
}

if err := v.NameScoped.Init(ctx); err != nil {
Expand All @@ -68,7 +68,7 @@ func (v *UploadPutBlob) Init(ctx context.Context) error {
if value, ok := uploadcache.UploadCacheFromContext(ctx); ok {
v.uploadCache = value
} else {
return fmt.Errorf("missing provider %T", v.uploadCache)
return fmt.Errorf("missing provider %T.uploadCache", v)
}

if err := v.NameScoped.Init(ctx); err != nil {
Expand Down
24 changes: 24 additions & 0 deletions pkg/registryhttp/apis/registry/zz_generated.operator.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,10 @@ func init() {
R.Register(courier.NewRouter(&HeadBlob{}))
}

func (*HeadBlob) ResponseStatusCode() int {
return 200
}

func (*HeadBlob) ResponseContent() any {
return new(any)
}
Expand All @@ -100,6 +104,10 @@ func init() {
R.Register(courier.NewRouter(&HeadManifest{}))
}

func (*HeadManifest) ResponseStatusCode() int {
return 200
}

func (*HeadManifest) ResponseContent() any {
return new(any)
}
Expand All @@ -124,6 +132,10 @@ func init() {
R.Register(courier.NewRouter(&PutManifest{}))
}

func (*PutManifest) ResponseStatusCode() int {
return 200
}

func (*PutManifest) ResponseContent() any {
return new(any)
}
Expand All @@ -136,6 +148,10 @@ func init() {
R.Register(courier.NewRouter(&UploadBlob{}))
}

func (*UploadBlob) ResponseStatusCode() int {
return 201
}

func (*UploadBlob) ResponseContent() any {
return new(any)
}
Expand All @@ -148,6 +164,10 @@ func init() {
R.Register(courier.NewRouter(&UploadPatchBlob{}))
}

func (*UploadPatchBlob) ResponseStatusCode() int {
return 202
}

func (*UploadPatchBlob) ResponseContent() any {
return new(any)
}
Expand All @@ -160,6 +180,10 @@ func init() {
R.Register(courier.NewRouter(&UploadPutBlob{}))
}

func (*UploadPutBlob) ResponseStatusCode() int {
return 201
}

func (*UploadPutBlob) ResponseContent() any {
return new(any)
}
Expand Down
1 change: 1 addition & 0 deletions pkg/uploadcache/zz_generated.injectable.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
)

func (p *MemUploadCache) InjectContext(ctx context.Context) context.Context {

return UploadCacheInjectContext(ctx, p)
}

Expand Down

0 comments on commit bcde5c1

Please sign in to comment.