Getting started:
{{- if .Values.ingress.enabled }}
{{- range $host := .Values.ingress.hosts }}
  {{- range .paths }}
  http{{ if $.Values.ingress.tls }}s{{ end }}://{{ $host.host }}{{ .path }}
  {{- end }}
{{- end }}
{{- else if contains "NodePort" .Values.service.type }}

  export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "agentstack.fullname" . }})
  export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
  echo http://$NODE_IP:$NODE_PORT
{{- else if contains "LoadBalancer" .Values.service.type }}

     NOTE: It may take a few minutes for the LoadBalancer IP to be available.
           You can watch its status by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w agentstack-server-svc'
  export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} --agentstack-server-svc --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
  echo http://$SERVICE_IP:{{ .Values.service.port }}
{{- else if contains "ClusterIP" .Values.service.type }}

    # port-forward the API
    kubectl port-forward svc/agentstack-server-svc 8333:{{.Values.service.port}} &

    # use the agentstack CLI to setup the environment
    {{- if .Values.auth.enabled }}
    AGENTSTACK__ADMIN_PASSWORD={{.Values.auth.adminPassword}} agentstack model setup
    {{- else}}
    agentstack model setup
    {{- end}}
    {{- if .Values.ui.enabled }}

    # port-forward the UI
    kubectl port-forward svc/agentstack-ui-svc 8334:{{.Values.service.port}} &

    # Open the UI in the browser
    agentstack ui
    {{- end }}
{{- end }}

📄 See the documentation for more details and troubleshooting steps: https://agentstack.beeai.dev/how-to/deployment-guide

Resources:

    📚 Documentation: https://agentstack.beeai.dev
    💬 Discord Community: https://discord.gg/NradeA6ZNF
    📝 GitHub Issues: https://github.com/i-am-bee/agentstack/issues

Upgrade platform:

    helm upgrade {{ .Release.Name }} oci://ghcr.io/i-am-bee/agentstack/agentstack-chart/agentstack:<version>

{{- if .Values.phoenix.enabled }}

Important License Notice:

    When you enable Phoenix, be aware that Arize Phoenix is licensed under the Elastic License v2 (ELv2), which has
    specific terms regarding commercial use and distribution. By enabling Phoenix, you acknowledge that you are
    responsible for ensuring compliance with the ELv2 license terms for your specific use case. Please review the
    Phoenix license (https://github.com/Arize-ai/phoenix/blob/main/LICENSE) before enabling this feature in
    production environments.
{{- end }}
