-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
WiP - streaming events from pubsub to the HTTP webhook
- Loading branch information
1 parent
5e41f9d
commit 9a44d5a
Showing
30 changed files
with
4,226 additions
and
134 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
60 changes: 0 additions & 60 deletions
60
helm/provider/templates/runcompletion/eventsource_server.yaml
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{{/* | ||
Common labels | ||
*/}} | ||
{{- define "kfp-operator-provider.service.labels" -}} | ||
app: {{ include "kfp-operator-provider.resource-prefix" . }}-service | ||
provider: {{ .Values.provider.name }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{{- $providerName := .Values.provider.name }} | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: {{ include "kfp-operator-provider.resource-prefix" $ }}-service-config | ||
namespace: {{ include "kfp-operator-provider.namespace" $ }} | ||
data: | ||
config.yaml: | | ||
providerName: {{ $providerName }} | ||
operatorWebhook: http://{{ .Values.kfpOperator.fullname}}-runcompletion-webhook-service/events | ||
pod: | ||
namespace: to-be-overridden |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
{{- $providerName := .Values.provider.name }} | ||
{{- $labels := include "kfp-operator-provider.service.labels" $ }} | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: {{ include "kfp-operator-provider.resource-prefix" $ }}-{{ $providerName }}-service | ||
namespace: {{ include "kfp-operator-provider.namespace" $ }} | ||
labels: | ||
{{- $labels | nindent 4 }} | ||
spec: | ||
selector: | ||
matchLabels: | ||
{{- $labels | nindent 6 }} | ||
replicas: 1 | ||
template: | ||
metadata: | ||
{{- (deepCopy $.Values.service.metadata | merge (dict "labels" ($labels | fromYaml))) | toYaml | nindent 6 }} | ||
spec: | ||
serviceAccountName: {{ .Values.service.serviceAccount.name }} | ||
securityContext: | ||
runAsNonRoot: true | ||
containers: | ||
- name: provider-service | ||
image: {{ include "kfp-operator-provider-service.image" $ }} | ||
securityContext: | ||
allowPrivilegeEscalation: false | ||
resources: | ||
{{- $.Values.service.resources | toYaml | nindent 10 }} | ||
env: | ||
- name: POD_NAMESPACE | ||
valueFrom: | ||
fieldRef: | ||
fieldPath: metadata.namespace | ||
volumeMounts: | ||
- name: config | ||
mountPath: /etc/provider-service/config.yaml | ||
subPath: config.yaml | ||
volumes: | ||
- name: config | ||
configMap: | ||
name: {{ include "kfp-operator-provider.resource-prefix" . }}-service-config |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
FROM gcr.io/distroless/static-debian12:nonroot | ||
|
||
COPY bin/provider-service /bin/provider-service | ||
|
||
COPY internal/config/config.yaml /etc/provider-service/config.yaml | ||
|
||
CMD ["/bin/provider-service"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
include ../docker-targets.mk | ||
|
||
IMG := kfp-operator-provider-service | ||
|
||
build: | ||
CGO_ENABLED=0 GOOS=$(GOOS) GOARCH=$(GOARCH) go build -o bin/provider-service ./main.go | ||
|
||
test: | ||
go test ./... -tags=unit | ||
|
||
#functional-test: docker-build | ||
# docker compose up -d | ||
# go test ./... -tags=functional | ||
# docker compose down |
Oops, something went wrong.