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

Enable HTTP API for Nexus #511

Merged
merged 2 commits into from
Jun 25, 2024
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
8 changes: 8 additions & 0 deletions charts/temporal/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,14 @@ Source: https://stackoverflow.com/a/52024583/3027614
{{- end -}}
{{- end -}}

{{- define "temporal.frontend.httpPort" -}}
{{- if $.Values.server.frontend.service.httpPort -}}
{{- $.Values.server.frontend.service.httpPort -}}
{{- else -}}
{{- 7243 -}}
{{- end -}}
{{- end -}}

{{- define "temporal.frontend.membershipPort" -}}
{{- if $.Values.server.frontend.service.membershipPort -}}
{{- $.Values.server.frontend.service.membershipPort -}}
Expand Down
2 changes: 2 additions & 0 deletions charts/temporal/templates/server-configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ data:
frontend:
rpc:
grpcPort: {{ include "temporal.frontend.grpcPort" $ }}
httpPort: {{ include "temporal.frontend.httpPort" $ }}
membershipPort: {{ include "temporal.frontend.membershipPort" $ }}
bindOnIP: "0.0.0.0"

Expand Down Expand Up @@ -160,6 +161,7 @@ data:
initialFailoverVersion: 1
rpcName: "temporal-frontend"
rpcAddress: "127.0.0.1:7233"
httpAddress: "127.0.0.1:7243"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to worry about / can we generate a UUID for cluster ID here? Now that we are relying on it being present for temporalio/temporal#6184

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The cluster ID is auto-generated.

$ temporal operator cluster describe --output json
{
  ...
  "clusterId": "855e5c4b-d994-4c72-a09b-3c18e5161bb2",
  ...
}

{{- end }}

{{- if $.Values.server.config.dcRedirectionPolicy }}
Expand Down
5 changes: 5 additions & 0 deletions charts/temporal/templates/server-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,11 @@ spec:
- name: rpc
containerPort: {{ include (printf "temporal.%s.grpcPort" $service) $ }}
protocol: TCP
{{- if eq $service "frontend" }}
- name: http
containerPort: {{ include (printf "temporal.%s.httpPort" $service) $ }}
protocol: TCP
{{- end }}
- name: metrics
containerPort: 9090
protocol: TCP
Expand Down
5 changes: 5 additions & 0 deletions charts/temporal/templates/server-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ spec:
{{- if hasKey .Values.server.frontend.service "nodePort" }}
nodePort: {{ .Values.server.frontend.service.nodePort }}
{{- end }}
- port: {{ .Values.server.frontend.service.httpPort }}
targetPort: http
protocol: TCP
name: http
# TODO: Allow customizing the node HTTP port
selector:
app.kubernetes.io/name: {{ include "temporal.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
Expand Down
1 change: 1 addition & 0 deletions charts/temporal/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,7 @@ server:
annotations: {} # Evaluated as template
type: ClusterIP
port: 7233
httpPort: 7243
metrics:
annotations:
enabled: true
Expand Down