Skip to content
This repository was archived by the owner on Sep 9, 2020. It is now read-only.
This repository was archived by the owner on Sep 9, 2020. It is now read-only.

ks import -f some-component.yaml does not set component index in components/params.libsonnet #437

@jessesuen

Description

@jessesuen

Is this a BUG REPORT or FEATURE REQUEST?: BUG REPORT
/kind bug

What happened:

After importing a yaml using ks import, the params.libsonnet is missing the -X index.

$ ks import -f ~/tmp/kube-ops-view-deploy.yaml
INFO Writing component at '/Users/jsuen/ws/myapps/kube-ops-view/components/kube-ops-view-deploy.yaml'

$ cat components/params.libsonnet
{
  global: {
  },
  components: {
    // Component-level parameters, defined initially from 'ks prototype use ...'
    // Each object below should correspond to a component in the components/ directory
    "kube-ops-view-deploy": {

    },
  },
}

What you expected to happen:

According to chat with @bryanl, the component name in params.libsonnet should be: "kube-ops-view-deploy-0" instead of "kube-ops-view-deploy"

How to reproduce it (as minimally and precisely as possible): See above

Environment:

  • ksonnet version (use ks version):
$ ks version
ksonnet version: 0.10.0-alpha.1
jsonnet version: v0.10.0
client-go version: 1.8

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions