-
Notifications
You must be signed in to change notification settings - Fork 5
infra: deploy orcha with helm #27
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
Open
mairasalazar
wants to merge
3
commits into
inveniosoftware:main
Choose a base branch
from
mairasalazar:dev-deployment
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 |
|---|---|---|
|
|
@@ -72,7 +72,7 @@ def workers(): | |
| """Start the Temporal worker.""" | ||
| typer.echo("Starting Temporal worker...") | ||
| result = subprocess.run( | ||
| ["uv", "run", "python", "-m", "app.workers"], | ||
|
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Changed the CLI command to use sys.executable instead of uv run python, because then we use the interpreter currently running without creating a cache and failing due to permissions |
||
| [sys.executable, "-m", "app.workers"], | ||
| cwd=PROJECT_ROOT, | ||
| ) | ||
| sys.exit(result.returncode) | ||
|
|
@@ -91,7 +91,7 @@ def run_all(ctx: typer.Context): | |
| cwd=PROJECT_ROOT, | ||
| ), | ||
| subprocess.Popen( | ||
| ["uv", "run", "python", "-m", "app.workers"], | ||
| [sys.executable, "-m", "app.workers"], | ||
| cwd=PROJECT_ROOT, | ||
| ), | ||
| ] | ||
|
|
||
This file contains hidden or 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 hidden or 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 hidden or 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,9 @@ | ||
| dependencies: | ||
| - name: postgresql | ||
| repository: https://charts.bitnami.com/bitnami | ||
| version: 18.5.7 | ||
| - name: temporal | ||
| repository: https://go.temporal.io/helm-charts | ||
| version: 0.73.1 | ||
| digest: sha256:e560849947eb28377fb837ff5e664918e610cb6b1c287109472e5d35019c9c5d | ||
| generated: "2026-03-18T18:44:55.62055+01:00" |
This file contains hidden or 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,16 @@ | ||
| apiVersion: v2 | ||
| name: orcha | ||
| description: Orcha AI workflow service | ||
| type: application | ||
| version: 0.1.0 | ||
| appVersion: "0.1.0" | ||
|
|
||
| dependencies: | ||
| - name: postgresql | ||
| version: "18.5.7" | ||
| repository: https://charts.bitnami.com/bitnami | ||
| condition: postgresql.enabled | ||
| - name: temporal | ||
| version: "0.73.1" | ||
| repository: https://go.temporal.io/helm-charts | ||
| condition: temporal.enabled |
Binary file not shown.
Binary file not shown.
Empty file.
This file contains hidden or 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,15 @@ | ||
| apiVersion: v1 | ||
| kind: ConfigMap | ||
| metadata: | ||
| name: {{ include "orcha.fullname" . }} | ||
| labels: | ||
| {{- include "orcha.labels" . | nindent 4 }} | ||
| data: | ||
| AUTH_DISABLED: {{ .Values.config.authDisabled | quote }} | ||
| TEMPORAL_HOST: {{ tpl .Values.config.temporalHost . | quote }} | ||
| TEMPORAL_NAMESPACE: {{ .Values.config.temporalNamespace | quote }} | ||
| PGUSER: {{ .Values.postgresqlExternal.username | quote }} | ||
| PGHOST: {{ .Values.postgresqlExternal.hostname | quote }} | ||
| PGPORT: {{ .Values.postgresqlExternal.port | quote }} | ||
| PGDATABASE: {{ .Values.postgresqlExternal.database | quote }} | ||
|
|
This file contains hidden or 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,62 @@ | ||
| --- | ||
| apiVersion: apps/v1 | ||
| kind: Deployment | ||
| metadata: | ||
| name: {{ include "orcha.fullname" . }}-api | ||
| labels: | ||
| {{- include "orcha.labels" . | nindent 4 }} | ||
| app.kubernetes.io/component: api | ||
| spec: | ||
| replicas: {{ .Values.api.replicaCount }} | ||
| selector: | ||
| matchLabels: | ||
| {{- include "orcha.selectorLabels" . | nindent 6 }} | ||
| app.kubernetes.io/component: api | ||
| template: | ||
| metadata: | ||
| labels: | ||
| {{- include "orcha.selectorLabels" . | nindent 8 }} | ||
| app.kubernetes.io/component: api | ||
| spec: | ||
| containers: | ||
| - name: api | ||
| image: {{ include "orcha.image" . }} | ||
| imagePullPolicy: {{ .Values.image.pullPolicy }} | ||
| ports: | ||
| - name: http | ||
| containerPort: 8080 | ||
| protocol: TCP | ||
| envFrom: | ||
| - configMapRef: | ||
| name: {{ include "orcha.fullname" . }} | ||
| - secretRef: | ||
| name: {{ .Values.externalSecret.name }} | ||
| env: | ||
| {{- include "orcha.config.database" . | nindent 10 }} | ||
| - name: TENANTS_FILE_PATH | ||
| value: /etc/orcha/tenants.json | ||
| volumeMounts: | ||
| - name: tenants | ||
| mountPath: /etc/orcha | ||
| readOnly: true | ||
| livenessProbe: | ||
| httpGet: | ||
| path: /health | ||
| port: http | ||
| initialDelaySeconds: 15 | ||
| periodSeconds: 30 | ||
| readinessProbe: | ||
| httpGet: | ||
| path: /health | ||
| port: http | ||
| initialDelaySeconds: 10 | ||
| periodSeconds: 10 | ||
| resources: | ||
| {{- toYaml .Values.api.resources | nindent 12 }} | ||
| volumes: | ||
| - name: tenants | ||
| secret: | ||
| secretName: orcha-tenants | ||
| items: | ||
| - key: tenants.json | ||
| path: tenants.json |
This file contains hidden or 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,32 @@ | ||
| apiVersion: apps/v1 | ||
| kind: Deployment | ||
| metadata: | ||
| name: {{ include "orcha.fullname" . }}-worker | ||
| labels: | ||
| {{- include "orcha.labels" . | nindent 4 }} | ||
| app.kubernetes.io/component: worker | ||
| spec: | ||
| replicas: {{ .Values.worker.replicaCount }} | ||
| selector: | ||
| matchLabels: | ||
| {{- include "orcha.selectorLabels" . | nindent 6 }} | ||
| app.kubernetes.io/component: worker | ||
| template: | ||
| metadata: | ||
| labels: | ||
| {{- include "orcha.selectorLabels" . | nindent 8 }} | ||
| app.kubernetes.io/component: worker | ||
| spec: | ||
| containers: | ||
| - name: worker | ||
| image: {{ include "orcha.image" . }} | ||
| imagePullPolicy: {{ .Values.image.pullPolicy }} | ||
| command: ["/app/.venv/bin/orcha", "run", "workers"] | ||
| envFrom: | ||
| - configMapRef: | ||
| name: {{ include "orcha.fullname" . }} | ||
| - secretRef: | ||
| name: {{ include "orcha.fullname" . }} | ||
|
|
||
| resources: | ||
| {{- toYaml .Values.worker.resources | nindent 12 }} |
This file contains hidden or 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,21 @@ | ||
| {{- if .Capabilities.APIVersions.Has "route.openshift.io/v1/Route" }} | ||
| --- | ||
| apiVersion: route.openshift.io/v1 | ||
| kind: Route | ||
| metadata: | ||
| name: {{ include "orcha.fullname" . }} | ||
| {{- if and .Values.route .Values.route.annotations }} | ||
| annotations: | ||
| {{- .Values.route.annotations | toYaml | nindent 4 }} | ||
| {{- end }} | ||
| spec: | ||
| host: {{ include "orcha.hostname" $ }} | ||
| to: | ||
| kind: Service | ||
| name: {{ include "orcha.fullname" . }}-api | ||
| port: | ||
| targetPort: http | ||
| tls: | ||
| termination: edge | ||
| insecureEdgeTerminationPolicy: Redirect | ||
| {{- end }} |
This file contains hidden or 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,17 @@ | ||
| apiVersion: v1 | ||
| kind: Service | ||
| metadata: | ||
| name: {{ include "orcha.fullname" . }}-api | ||
| labels: | ||
| {{- include "orcha.labels" . | nindent 4 }} | ||
| app.kubernetes.io/component: api | ||
| spec: | ||
| type: {{ .Values.api.service.type }} | ||
| ports: | ||
| - port: {{ .Values.api.service.port }} | ||
| targetPort: http | ||
| protocol: TCP | ||
| name: http | ||
| selector: | ||
| {{- include "orcha.selectorLabels" . | nindent 4 }} | ||
| app.kubernetes.io/component: api |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed Dockerfile CMD port from 80 to 8080 because port 80 requires root privileges and OpenShift runs containers as non-root