kops/cmd
Kubernetes Submit Queue 10ce978b64 Merge pull request #3040 from mad01/templating
Automatic merge from submit-queue

MVP of templating 

MVP implementation of templating to generate cluster.yaml file: related to #2404 implementation is using the `text/template`

```bash
cat > values.yaml <<EOF
clusterName: eu1
kubernetesVersion: 1.7.1
dnsZone: k8s.example.com
awsRegion: eu-west-1
EOF
```

```bash
cat > cluster.tmpl.yaml <<EOF
apiVersion: kops/v1alpha2
kind: InstanceGroup
metadata:
  labels:
	kops.k8s.io/cluster: {{.clusterName}}.{{.dnsZone}}
  name: nodes
spec:
  image: coreos.com/CoreOS-stable-1409.6.0-hvm
  machineType: m4.large
  maxPrice: "0.5"
  maxSize: 2
  minSize: 15
  role: Node
  rootVolumeSize: 100
  subnets:
  - {{.awsRegion}}a
  - {{.awsRegion}}b
  - {{.awsRegion}}c

EOF
```

running the templating command
```bash
  kops toolbox template \
      --values values.yaml \
      --template cluster.tmpl.yaml \
      --output cluster.yaml
```

output
```bash
apiVersion: kops/v1alpha2
kind: InstanceGroup
metadata:
  labels:
	kops.k8s.io/cluster: eu1.k8s.example.com
  name: nodes
spec:
  image: coreos.com/CoreOS-stable-1409.6.0-hvm
  machineType: m4.large
  maxPrice: "0.5"
  maxSize: 2
  minSize: 15
  role: Node
  rootVolumeSize: 100
  subnets:
  - eu-west-1a
  - eu-west-1b
  - eu-west-1c
```
2017-08-04 09:26:41 -07:00
..
kops Merge pull request #3040 from mad01/templating 2017-08-04 09:26:41 -07:00
kops-server Fixing headers for ci 2017-03-28 06:42:21 +02:00
nodeup Add missed error handling from nodeup lstat 2017-04-07 23:46:31 -04:00