Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: upgrade k8s.io to 0.26 and kubevela to 1.9.0 #783

Merged
merged 1 commit into from
Apr 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified .DS_Store
Binary file not shown.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ e2e-setup-core: install-vela install-core install-addon

.PHONY: install-vela
install-vela:
curl -fsSl https://kubevela.io/script/install.sh | bash
curl -fsSl https://kubevela.io/script/install.sh | bash -s v1.9.0-alpha.2
install-core:
vela install -y
install-addon:
Expand Down
5 changes: 5 additions & 0 deletions addon/config-templates/image-registry.cue
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import (
"encoding/base64"
"encoding/json"
"strconv"
"vela/config"
)

metadata: {
Expand Down Expand Up @@ -52,6 +53,10 @@ template: {
}
}

validation: config.#ImageRegistry & {
$params: parameter
}

parameter: {
// +usage=Image registry FQDN, such as: index.docker.io
registry: *"index.docker.io" | string
Expand Down
140 changes: 65 additions & 75 deletions go.mod

Large diffs are not rendered by default.

335 changes: 188 additions & 147 deletions go.sum

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion pkg/plugin/proxy/proxy_suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ var _ = BeforeSuite(func(done Done) {
testEnv = &envtest.Environment{
ControlPlaneStartTimeout: time.Minute * 3,
ControlPlaneStopTimeout: time.Minute,
UseExistingCluster: pointer.BoolPtr(false),
UseExistingCluster: pointer.Bool(false),
}

By("start kube test env")
Expand Down
2 changes: 1 addition & 1 deletion pkg/server/domain/repository/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ var _ = BeforeSuite(func(done Done) {
testEnv = &envtest.Environment{
ControlPlaneStartTimeout: time.Minute * 3,
ControlPlaneStopTimeout: time.Minute,
UseExistingCluster: pointer.BoolPtr(false),
UseExistingCluster: pointer.Bool(false),
CRDDirectoryPaths: []string{"../../../../test/crds"},
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/server/domain/service/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ var _ = BeforeSuite(func(done Done) {
testEnv = &envtest.Environment{
ControlPlaneStartTimeout: time.Minute * 3,
ControlPlaneStopTimeout: time.Minute,
UseExistingCluster: pointer.BoolPtr(false),
UseExistingCluster: pointer.Bool(false),
CRDDirectoryPaths: []string{"../../../../test/crds", "./testdata/crds"},
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/server/event/collect/suit_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ var _ = BeforeSuite(func(done Done) {
testEnv = &envtest.Environment{
ControlPlaneStartTimeout: time.Minute * 3,
ControlPlaneStopTimeout: time.Minute,
UseExistingCluster: pointer.BoolPtr(false),
UseExistingCluster: pointer.Bool(false),
CRDDirectoryPaths: []string{"../../../../test/crds"},
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/server/event/sync/suit_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ var _ = BeforeSuite(func(done Done) {
testEnv = &envtest.Environment{
ControlPlaneStartTimeout: time.Minute * 3,
ControlPlaneStopTimeout: time.Minute,
UseExistingCluster: pointer.BoolPtr(false),
UseExistingCluster: pointer.Bool(false),
CRDDirectoryPaths: []string{"../../../../test/crds"},
}

Expand Down
5 changes: 4 additions & 1 deletion pkg/server/event/sync/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,10 @@ func (a *ApplicationSync) Start(ctx context.Context, errorChan chan error) {
klog.Infof("delete the application (%s/%s) metadata successfully", app.Namespace, app.Name)
},
}
informer.AddEventHandler(handlers)
_, err = informer.AddEventHandler(handlers)
if err != nil {
klog.ErrorS(err, "failed to add event handler for application sync")
}
klog.Info("app syncing started")
informer.Run(ctx.Done())
}
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ var _ = BeforeSuite(func(done Done) {
testEnv = &envtest.Environment{
ControlPlaneStartTimeout: time.Minute * 3,
ControlPlaneStopTimeout: time.Minute,
UseExistingCluster: pointer.BoolPtr(false),
UseExistingCluster: pointer.Bool(false),
}

By("start kube test env")
Expand Down
2 changes: 1 addition & 1 deletion pkg/server/interfaces/api/api_suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ var _ = BeforeSuite(func(done Done) {
testEnv = &envtest.Environment{
ControlPlaneStartTimeout: time.Minute * 3,
ControlPlaneStopTimeout: time.Minute,
UseExistingCluster: pointer.BoolPtr(false),
UseExistingCluster: pointer.Bool(false),
CRDDirectoryPaths: []string{"../../../test/crds"},
}

Expand Down
6 changes: 3 additions & 3 deletions pkg/server/utils/auth.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ func (c *authClient) Status() client.StatusWriter {
}

// Get .
func (c *authClient) Get(ctx context.Context, key client.ObjectKey, obj client.Object) error {
func (c *authClient) Get(ctx context.Context, key client.ObjectKey, obj client.Object, _ ...client.GetOption) error {
ctx = ContextWithUserInfo(ctx)
return c.Client.Get(ctx, key, obj)
}
Expand Down Expand Up @@ -141,13 +141,13 @@ type authAppStatusClient struct {
}

// Update .
func (c *authAppStatusClient) Update(ctx context.Context, obj client.Object, opts ...client.UpdateOption) error {
func (c *authAppStatusClient) Update(ctx context.Context, obj client.Object, opts ...client.SubResourceUpdateOption) error {
ctx = ContextWithUserInfo(ctx)
return c.StatusWriter.Update(ctx, obj, opts...)
}

// Patch .
func (c *authAppStatusClient) Patch(ctx context.Context, obj client.Object, patch client.Patch, opts ...client.PatchOption) error {
func (c *authAppStatusClient) Patch(ctx context.Context, obj client.Object, patch client.Patch, opts ...client.SubResourcePatchOption) error {
ctx = ContextWithUserInfo(ctx)
return c.StatusWriter.Patch(ctx, obj, patch, opts...)
}