Skip to content

Commit

Permalink
Updated anyscale-operator (#3)
Browse files Browse the repository at this point in the history
Co-authored-by: anyscale-helm-bot <[email protected]>
  • Loading branch information
csivanich and anyscale-helm-bot authored Nov 21, 2024
1 parent 3dcbc0c commit 2a6f1f3
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 1 deletion.
2 changes: 1 addition & 1 deletion charts/anyscale-operator/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
apiVersion: v2
name: anyscale-operator
version: 0.0.3
version: 0.1.0
20 changes: 20 additions & 0 deletions charts/anyscale-operator/templates/configmap_patches.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,26 @@ data:
{{- end }}
{{- end }}
########################################
# Instance Type Configurations (put these below the other patches so
# that instance-type specific patches can override the default patches).
########################################
{{- $defaultInstanceTypesCopy := deepCopy (default dict .Values.defaultInstanceTypes) }}
{{- $additionalInstanceTypesCopy := deepCopy (default dict .Values.additionalInstanceTypes) }}
{{- $instanceTypes := merge $defaultInstanceTypesCopy $additionalInstanceTypesCopy }}
{{- range $instanceType, $config := $instanceTypes }}
{{- if $config.nodeSelector }}
- kind: Pod
selector: "anyscale.com/instance-type in ({{ $instanceType }})"
patch:
{{- range $key, $value := $config.nodeSelector }}
- op: add
path: /spec/nodeSelector/{{ $key | replace "/" "~1" }}
value: "{{ $value }}"
{{- end }}
{{- end }}
{{- end }}
########################################
# Additional Patches
########################################
Expand Down
3 changes: 3 additions & 0 deletions charts/anyscale-operator/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@ operatorResources:

# defaultInstanceTypes provides a list of default Pod shapes that can be
# used in Anyscale workloads (abstracted as virtual "instance types").
#
# Node selectors that apply specifically to these instance types can be
# placed directly under each instance type under the `nodeSelector` key.
defaultInstanceTypes:
2CPU-8GB:
resources:
Expand Down

0 comments on commit 2a6f1f3

Please sign in to comment.