Skip to content

Error converting YAML to JSON could not find expected ':' #26

@ynarwal

Description

@ynarwal

I am getting this error

 
  pulumi:pulumi:Stack (acf-deployment-staging):
    2021/01/12 12:46:32 warning: skipped value for filters: Not a table.
 
    unhandled rejection: CONTEXT(7638): Invoking function: tok=kubernetes:helm:template asynchronously
    STACK_TRACE:
    Error:
        at Object.debuggablePromise (/Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/debuggable.js:69:75)
        at /Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/invoke.js:126:45
        at Generator.next (<anonymous>)
        at fulfilled (/Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/invoke.js:18:58)
        at runMicrotasks (<anonymous>)
        at processTicksAndRejections (internal/process/task_queues.js:93:5)
    unhandled rejection: CONTEXT(7638): Invoking function: tok=kubernetes:helm:template asynchronously
    STACK_TRACE:
    Error:
        at Object.debuggablePromise (/Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/debuggable.js:69:75)
        at /Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/invoke.js:126:45
        at Generator.next (<anonymous>)
        at fulfilled (/Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/invoke.js:18:58)
        at runMicrotasks (<anonymous>)
        at processTicksAndRejections (internal/process/task_queues.js:93:5)
    unhandled rejection: CONTEXT(7638): Invoking function: tok=kubernetes:helm:template asynchronously
    STACK_TRACE:
    Error:
        at Object.debuggablePromise (/Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/debuggable.js:69:75)
        at /Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/invoke.js:126:45
        at Generator.next (<anonymous>)
        at fulfilled (/Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/invoke.js:18:58)
        at runMicrotasks (<anonymous>)
        at processTicksAndRejections (internal/process/task_queues.js:93:5)
    unhandled rejection: CONTEXT(7638): Invoking function: tok=kubernetes:helm:template asynchronously
    STACK_TRACE:
    Error:
        at Object.debuggablePromise (/Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/debuggable.js:69:75)
        at /Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/invoke.js:126:45
        at Generator.next (<anonymous>)
        at fulfilled (/Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/invoke.js:18:58)
        at runMicrotasks (<anonymous>)
        at processTicksAndRejections (internal/process/task_queues.js:93:5)
 
    error: Running program '/Users/yash/blitzm/client_projects/acf-web-app/ops' failed with an unhandled exception:
    Error: invocation of kubernetes:helm:template returned an error: failed to generate YAML for specified Helm chart: failed to create chart from template: YAML parse error on grafana/templates/configmap.yaml: error converting YAML to JSON: yaml: line 39: could not find expected ':'
        at /Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@pulumi/pulumi/runtime/invoke.js:139:33
        at Http2CallStream.<anonymous> (/Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@grpc/grpc-js/src/client.ts:155:9)
        at Http2CallStream.emit (events.js:327:22)
        at Http2CallStream.EventEmitter.emit (domain.js:486:12)
        at /Users/yash/blitzm/client_projects/acf-web-app/ops/node_modules/@grpc/grpc-js/src/call-stream.ts:186:14
        at processTicksAndRejections (internal/process/task_queues.js:75:11)

by using GrafanaStack lib

...
import { GrafanaStack } from "@kloudlib/grafana-stack";
...

const monitoring = new GrafanaStack('monitoring', {
  provider: cluster.provider,
  namespace: 'kube-system',
  grafana: {
    version: '6.1.17',
    ingress: {
      enabled: true,
      hosts: [
        `monitoring.${appDomain}`
      ],
    },
  },
  prometheus: {
    version: '13.2.0',
    resources: {
      requests: {
        cpu: '80m',
        memory: '500Mi'
      },
      limits: {
        cpu: '100m',
        memory: '700Mi',
      },
    },
    persistence: {
      sizeGB: 10,
    }
  },
  loki: {
    retentionHours: 672, // 4 weeks
    persistence: {
      enabled: true,
      sizeGB: 10,
    }
  }
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions