Skip to content

Commit

Permalink
upgrade landscaper v0.71.0 (#193)
Browse files Browse the repository at this point in the history
Co-authored-by: Achim Weigel <[email protected]>
  • Loading branch information
reshnm and achimweigel authored Jul 19, 2023
1 parent 4e34a5b commit 21a792e
Show file tree
Hide file tree
Showing 1,510 changed files with 90,334 additions and 50,328 deletions.
2 changes: 1 addition & 1 deletion .ci/release
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set -o errexit
set -o nounset
set -o pipefail

apk add --no-cache git make musl-dev curl
apk add --no-cache git make musl-dev curl gcompat
curl -LO https://golang.org/dl/go1.20.linux-amd64.tar.gz
tar -C /usr/local -xzf go1.20.linux-amd64.tar.gz
export PATH=$PATH:/usr/local/go/bin
Expand Down
1 change: 1 addition & 0 deletions .golangci.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
run:
concurrency: 4
deadline: 10m
go: '1.20'

skip-files:
- "zz_generated.*\\.go$"
2 changes: 1 addition & 1 deletion .landscaper/landscaper-instance/component-references.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
componentName: github.com/gardener/landscaper
name: landscaper
version: v0.67.0
version: v0.71.0
...
21 changes: 11 additions & 10 deletions cmd/landscaper-service-webhooks-server/app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,18 +55,19 @@ func NewLandscaperServiceWebhooksCommand(ctx context.Context) *cobra.Command {
func (o *options) run(ctx context.Context) error {
o.log.Info(fmt.Sprintf("Start Landscaper Service Webhooks Server with version %q", version.Get().String()))

webhookServer := &ctrlwebhook.Server{
Port: o.port,
WebhookMux: http.NewServeMux(),
}

webhookServer.WebhookMux.Handle("/healthz", http.HandlerFunc(func(writer http.ResponseWriter, request *http.Request) {
opts := ctrlwebhook.Options{}
opts.Port = o.port
opts.WebhookMux = http.NewServeMux()
opts.WebhookMux.Handle("/healthz", http.HandlerFunc(func(writer http.ResponseWriter, request *http.Request) {
writer.Header().Set("Content-Type", "text/plain; charset=utf-8")
writer.Header().Set("X-Content-Type-Options", "nosniff")
if _, err := writer.Write([]byte("Ok")); err != nil {
o.log.Error(err, "unable to send health response")
}
}))
opts.CertDir = filepath.Join(os.TempDir(), "k8s-webhook-server", "serving-certs")
webhookServer := ctrlwebhook.NewServer(opts)

ctrl.SetLogger(o.log.Logr())

restConfig := ctrl.GetConfigOrDie()
Expand All @@ -80,7 +81,7 @@ func (o *options) run(ctx context.Context) error {
}

// create ValidatingWebhookConfiguration and register webhooks, if validation is enabled, delete it otherwise
if err := registerWebhooks(ctx, webhookServer, kubeClient, scheme, o); err != nil {
if err := registerWebhooks(ctx, webhookServer, kubeClient, scheme, opts.CertDir, o); err != nil {
return fmt.Errorf("unable to register validation webhook: %w", err)
}

Expand All @@ -92,9 +93,10 @@ func (o *options) run(ctx context.Context) error {
}

func registerWebhooks(ctx context.Context,
webhookServer *ctrlwebhook.Server,
webhookServer ctrlwebhook.Server,
kubeClient client.Client,
scheme *runtime.Scheme,
certDir string,
o *options) error {

webhookLogger := logging.Wrap(ctrl.Log.WithName("webhook").WithName("validation"))
Expand Down Expand Up @@ -130,10 +132,9 @@ func registerWebhooks(ctx context.Context,
}

// generate certificates
webhookServer.CertDir = filepath.Join(os.TempDir(), "k8s-webhook-server", "serving-certs")
var err error
dnsNames := webhookcert.GeDNSNamesFromNamespacedName(wo.ServiceNamespace, wo.ServiceName)
wo.CABundle, err = webhookcert.GenerateCertificates(ctx, kubeClient, webhookServer.CertDir, o.webhook.certificatesNamespace, "landscaper-service-webhook", "landscaper-service-webhook-cert", dnsNames)
wo.CABundle, err = webhookcert.GenerateCertificates(ctx, kubeClient, certDir, o.webhook.certificatesNamespace, "landscaper-service-webhook", "landscaper-service-webhook-cert", dnsNames)
if err != nil {
return fmt.Errorf("unable to generate webhook certificates: %w", err)
}
Expand Down
70 changes: 35 additions & 35 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,22 @@ go 1.20

require (
github.com/gardener/component-spec/bindings-go v0.0.66
github.com/gardener/landscaper/apis v0.67.0
github.com/gardener/landscaper/controller-utils v0.67.0
github.com/go-logr/logr v1.2.3
github.com/gardener/landscaper/apis v0.71.0
github.com/gardener/landscaper/controller-utils v0.71.0
github.com/go-logr/logr v1.2.4
github.com/google/uuid v1.3.0
github.com/onsi/ginkgo v1.16.5
github.com/onsi/gomega v1.24.1
github.com/onsi/gomega v1.27.7
github.com/pkg/errors v0.9.1
github.com/spf13/cobra v1.6.0
github.com/spf13/pflag v1.0.5
k8s.io/api v0.26.1
k8s.io/apimachinery v0.26.1
k8s.io/client-go v0.26.1
k8s.io/code-generator v0.26.1
k8s.io/kube-openapi v0.0.0-20230217203603-ff9a8e8fa21d
k8s.io/utils v0.0.0-20230209194617-a36077c30491
sigs.k8s.io/controller-runtime v0.14.0
k8s.io/api v0.27.3
k8s.io/apimachinery v0.27.3
k8s.io/client-go v0.27.3
k8s.io/code-generator v0.27.2
k8s.io/kube-openapi v0.0.0-20230501164219-8b0f38b5fd1f
k8s.io/utils v0.0.0-20230406110748-d93618cff8a2
sigs.k8s.io/controller-runtime v0.15.0
)

require (
Expand All @@ -36,13 +36,13 @@ require (
github.com/fsnotify/fsnotify v1.6.0 // indirect
github.com/ghodss/yaml v1.0.0 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-logr/zapr v1.2.3 // indirect
github.com/go-logr/zapr v1.2.4 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.2 // indirect
github.com/go-openapi/swag v0.22.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.2 // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/cel-go v0.12.6 // indirect
github.com/google/gnostic v0.5.7-v3refs // indirect
github.com/google/go-cmp v0.5.9 // indirect
Expand All @@ -53,21 +53,21 @@ require (
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.2 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect
github.com/mitchellh/mapstructure v1.4.1 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/nxadm/tail v1.4.8 // indirect
github.com/prometheus/client_golang v1.14.0 // indirect
github.com/prometheus/client_model v0.3.0 // indirect
github.com/prometheus/common v0.37.0 // indirect
github.com/prometheus/procfs v0.8.0 // indirect
github.com/prometheus/client_golang v1.15.1 // indirect
github.com/prometheus/client_model v0.4.0 // indirect
github.com/prometheus/common v0.42.0 // indirect
github.com/prometheus/procfs v0.9.0 // indirect
github.com/stoewer/go-strcase v1.2.0 // indirect
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f // indirect
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect
github.com/xeipuuv/gojsonschema v1.2.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.35.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.35.1 // indirect
go.opentelemetry.io/otel v1.10.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.10.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.10.0 // indirect
Expand All @@ -79,31 +79,31 @@ require (
go.uber.org/atomic v1.7.0 // indirect
go.uber.org/multierr v1.6.0 // indirect
go.uber.org/zap v1.24.0 // indirect
golang.org/x/crypto v0.6.0 // indirect
golang.org/x/mod v0.7.0 // indirect
golang.org/x/net v0.6.0 // indirect
golang.org/x/oauth2 v0.4.0 // indirect
golang.org/x/sys v0.5.0 // indirect
golang.org/x/term v0.5.0 // indirect
golang.org/x/text v0.7.0 // indirect
golang.org/x/crypto v0.10.0 // indirect
golang.org/x/mod v0.10.0 // indirect
golang.org/x/net v0.10.0 // indirect
golang.org/x/oauth2 v0.5.0 // indirect
golang.org/x/sys v0.9.0 // indirect
golang.org/x/term v0.9.0 // indirect
golang.org/x/text v0.10.0 // indirect
golang.org/x/time v0.3.0 // indirect
golang.org/x/tools v0.4.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.2.0 // indirect
golang.org/x/tools v0.9.1 // indirect
gomodules.xyz/jsonpatch/v2 v2.3.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20230110181048-76db0878b65f // indirect
google.golang.org/grpc v1.53.0 // indirect
google.golang.org/protobuf v1.28.1 // indirect
google.golang.org/protobuf v1.30.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/apiextensions-apiserver v0.26.1 // indirect
k8s.io/apiserver v0.26.1 // indirect
k8s.io/component-base v0.26.1 // indirect
k8s.io/apiextensions-apiserver v0.27.2 // indirect
k8s.io/apiserver v0.27.2 // indirect
k8s.io/component-base v0.27.2 // indirect
k8s.io/gengo v0.0.0-20220902162205-c0856e24416d // indirect
k8s.io/klog/v2 v2.80.1 // indirect
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.35 // indirect
sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 // indirect
k8s.io/klog/v2 v2.90.1 // indirect
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.1.2 // indirect
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect
sigs.k8s.io/yaml v1.3.0 // indirect
)
Expand Down
Loading

0 comments on commit 21a792e

Please sign in to comment.