nats-io / k8s

NATS on Kubernetes with Helm Charts
Apache License 2.0
444 stars 300 forks source link

[Nats helm] Error: parse error at (nats/templates/tests/request-reply.yaml:8): unclosed action #888

Closed faizanbashir closed 4 months ago

faizanbashir commented 4 months ago

What version were you using?

Helm chart appVersion: 2.10.12 version: 1.1.10

What environment was the server running in?

Azure Kubernetes Service

Is this defect reproducible?

helm upgrade --install nats nats/nats --values values.yaml

Given the capability you are leveraging, describe your expectation?

The helm install command should not result in error.

Given the expectation, what is the defect you are observing?

helm upgrade --install nats nats/nats --values values.yaml
Error: parse error at (nats/templates/tests/request-reply.yaml:8): unclosed action
caleblloyd commented 4 months ago

Please include your values.yaml file that recreates this

faizanbashir commented 4 months ago

@caleblloyd, I used two values.yaml files. One was the default values.yaml given in the repo. Another is given below:

# values.yaml for NATS Helm chart

# Cluster configuration
cluster:
  enabled: false
  replicas: 3  # Number of NATS server nodes for high availability

# JetStream configuration
jetstream:
  enabled: true
  memStorage:
    enabled: true
    size: 2Gi  # Memory storage size for JetStream
  fileStorage:
    enabled: true
    size: 10Gi  # File storage size for JetStream
    storageDirectory: /data/jetstream  # Directory for file storage
    storageClassName: fast-ssd  # StorageClass for the persistent volume

# Resource allocation
resources:
  limits:
    cpu: 2  # CPU limit for each NATS server pod
    memory: 4Gi  # Memory limit for each NATS server pod
  requests:
    cpu: 1  # CPU request for each NATS server pod
    memory: 2Gi  # Memory request for each NATS server pod

# Security configuration
auth:
  enabled: false
  systemAccountEnabled: true  # Enable the system account for monitoring and administration
  users:
    - username: admin
      password: your-admin-password
      permissions:
        publish: ">"
        subscribe: ">"
    - username: app-user
      password: your-app-user-password
      permissions:
        publish: "foo.>"
        subscribe: "foo.>"

# Monitoring and metrics
metrics:
  enabled: true  # Enable Prometheus metrics
  port: 7777
  path: /metrics

# NATS Exporter for Prometheus
natsExporter:
  enabled: true
  image: natsio/prometheus-nats-exporter
  version: 0.9.0
  resources:
    requests:
      cpu: 100m
      memory: 128Mi
    limits:
      cpu: 200m
      memory: 256Mi
caleblloyd commented 4 months ago

This is the 0.x values.yaml format. You should continue to use chart version 0.19.17 until you upgrade

Here is the upgrade guide

faizanbashir commented 4 months ago

@caleblloyd, i tried the chart version 0.19.17 and looks like its working. Thanks.

Is there any reference file for the 1.x values.yaml?

caleblloyd commented 4 months ago

Great. Yes the best docs page is on ArtifactHub:

https://artifacthub.io/packages/helm/nats/nats