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

Use init container to download packages and functions #411

Merged
merged 6 commits into from
Sep 26, 2022
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
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ auth:
issuerUrlParam: https://sts.windows.net/06a8a086-ae6e-45b5-a22e-ad90de23013e/v2.0
audience: api://56c1bd14-3ba7-4804-b47b-d46de6dce33e
audienceParam: api://56c1bd14-3ba7-4804-b47b-d46de6dce33e/.default
brokerClientCredential: '{"client_id":"56c1bd14-3ba7-4804-b47b-d46de6dce33e","client_secret":"pBz8Q~ILXDKvC6-NS~zSlYsMF31avrrJsWo6PbNY"}'
brokerClientCredential: '{"client_id":"56c1bd14-3ba7-4804-b47b-d46de6dce33e","client_secret":"pBz8Q~ILXDKvC6-NS~zSlYsMF31avrrJsWo6PbNY","issuer_url":"https://sts.windows.net/06a8a086-ae6e-45b5-a22e-ad90de23013e/v2.0"}'
subjectClaim: appid
adminScope: appid
adminScopeParam: api://56c1bd14-3ba7-4804-b47b-d46de6dce33e/.default
Expand Down
3 changes: 3 additions & 0 deletions api/v1alpha1/function_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@ type FunctionSpec struct {
Replicas *int32 `json:"replicas,omitempty"`
// +kubebuilder:validation:Minimum=1
MinReplicas *int32 `json:"minReplicas,omitempty"`

DownloaderImage string `json:"downloaderImage,omitempty"`

// MaxReplicas indicates the maximum number of replicas and enables the HorizontalPodAutoscaler
// If provided, a default HPA with CPU at average of 80% will be used.
// For complex HPA strategies, please refer to Pod.HPAutoscaler.
Expand Down
3 changes: 3 additions & 0 deletions api/v1alpha1/sink_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ type SinkSpec struct {
Replicas *int32 `json:"replicas,omitempty"`
// +kubebuilder:validation:Minimum=1
MinReplicas *int32 `json:"minReplicas,omitempty"`

DownloaderImage string `json:"downloaderImage,omitempty"`

// MaxReplicas indicates the maximum number of replicas and enables the HorizontalPodAutoscaler
// If provided, a default HPA with CPU at average of 80% will be used.
// For complex HPA strategies, please refer to Pod.HPAutoscaler.
Expand Down
3 changes: 3 additions & 0 deletions api/v1alpha1/source_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ type SourceSpec struct {
Replicas *int32 `json:"replicas,omitempty"`
// +kubebuilder:validation:Minimum=1
MinReplicas *int32 `json:"minReplicas,omitempty"`

DownloaderImage string `json:"downloaderImage,omitempty"`

// MaxReplicas indicates the maximum number of replicas and enables the HorizontalPodAutoscaler
// If provided, a default HPA with CPU at average of 80% will be used.
// For complex HPA strategies, please refer to Pod.HPAutoscaler.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ spec:
type: string
deadLetterTopic:
type: string
downloaderImage:
type: string
forwardSourceMessageProperty:
type: boolean
funcConfig:
Expand Down Expand Up @@ -2879,6 +2881,8 @@ spec:
type: string
deadLetterTopic:
type: string
downloaderImage:
type: string
golang:
properties:
go:
Expand Down Expand Up @@ -5602,6 +5606,8 @@ spec:
type: string
clusterName:
type: string
downloaderImage:
type: string
forwardSourceMessageProperty:
type: boolean
golang:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ spec:
type: string
deadLetterTopic:
type: string
downloaderImage:
type: string
forwardSourceMessageProperty:
type: boolean
funcConfig:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ spec:
type: string
deadLetterTopic:
type: string
downloaderImage:
type: string
golang:
properties:
go:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ spec:
type: string
clusterName:
type: string
downloaderImage:
type: string
forwardSourceMessageProperty:
type: boolean
golang:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ spec:
type: string
deadLetterTopic:
type: string
downloaderImage:
type: string
forwardSourceMessageProperty:
type: boolean
funcConfig:
Expand Down Expand Up @@ -2881,6 +2883,8 @@ spec:
type: string
deadLetterTopic:
type: string
downloaderImage:
type: string
golang:
properties:
go:
Expand Down Expand Up @@ -5604,6 +5608,8 @@ spec:
type: string
clusterName:
type: string
downloaderImage:
type: string
forwardSourceMessageProperty:
type: boolean
golang:
Expand Down
2 changes: 2 additions & 0 deletions config/crd/bases/compute.functionmesh.io_functions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ spec:
type: string
deadLetterTopic:
type: string
downloaderImage:
type: string
forwardSourceMessageProperty:
type: boolean
funcConfig:
Expand Down
2 changes: 2 additions & 0 deletions config/crd/bases/compute.functionmesh.io_sinks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ spec:
type: string
deadLetterTopic:
type: string
downloaderImage:
type: string
golang:
properties:
go:
Expand Down
2 changes: 2 additions & 0 deletions config/crd/bases/compute.functionmesh.io_sources.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ spec:
type: string
clusterName:
type: string
downloaderImage:
type: string
forwardSourceMessageProperty:
type: boolean
golang:
Expand Down
Loading