{{- if $.Values.accounts.enabled }}
# OneUptime accounts Deployment
{{- $accountsEnv := dict "PORT" $.Values.accounts.ports.http "DISABLE_TELEMETRY" $.Values.accounts.disableTelemetryCollection -}}
{{- $accountsPorts := $.Values.accounts.ports -}}
{{- $accountsDeploymentArgs :=dict "IsUI" true "ServiceName" "accounts" "Ports" $accountsPorts "Release" $.Release "Values" $.Values "Env" $accountsEnv "Resources" $.Values.accounts.resources "NodeSelector" $.Values.accounts.nodeSelector "PodSecurityContext" $.Values.accounts.podSecurityContext "ContainerSecurityContext" $.Values.accounts.containerSecurityContext "DisableAutoscaler" $.Values.accounts.disableAutoscaler "ReplicaCount" $.Values.accounts.replicaCount -}}
{{- include "oneuptime.deployment" $accountsDeploymentArgs }}
---

# OneUptime accounts Service
{{- $accountsPorts := $.Values.accounts.ports -}}
{{- $accountsServiceArgs := dict "ServiceName" "accounts" "Ports" $accountsPorts "Release" $.Release "Values" $.Values -}}
{{- include "oneuptime.service" $accountsServiceArgs }}
---

# OneUptime accounts autoscaler
{{- $accountsAutoScalerArgs := dict "ServiceName" "accounts" "Release" $.Release "Values" $.Values "DisableAutoscaler" $.Values.accounts.disableAutoscaler -}}
{{- include "oneuptime.autoscaler" $accountsAutoScalerArgs }}
---
{{- end }}