rancher / rancher

Complete container management platform
http://rancher.com
Apache License 2.0
23.21k stars 2.94k forks source link

kubectl created ConfigMaps do not receive specified keys/values #5293

Closed nrvale0 closed 8 years ago

nrvale0 commented 8 years ago

Rancher Version: v1.1.0-dev5

Docker Version: Docker version 1.11.2, build b9f10c9

OS and where are the hosts located? (cloud, bare metal, etc): Ubuntu 14.04 on Digital Ocean. All latest patches.

Setup Details: (single node rancher vs. HA rancher, internal DB vs. external DB) Feed the following k8s manifest to Rancher via both local kubectl and via kubectl console in Rancher console.

https://github.com/nrvale0/rancher-k8s-puppet/blob/c689816316ec60ac9d38341f7fd196c825a79436/kubernetes-templates/puppet-standalone/0/cm-puppetserver-standalone.yml


---
apiVersion: v1
kind: ConfigMap
metadata:
  name: config-puppetserver-standalone
  namespace: default
data:
  controlrepo.git.uri: "from cm-puppetserver-standalone.yml"

Environment Type: (Cattle/Kubernetes/Swarm/Mesos) Kubernetes

Steps to Reproduce:

  1. Feed this manifest to Rancher via local kubectl.
  2. Note that the ConfigMap with specified key/value is present
  3. Delete the ConfigMap
  4. Feed this manifest via the kubectl in Rancher Console
  5. Note that ConfigMap is present but specified key/value is not present.

Note that the last behavior can be reproduced by attempting to create the ConfigMap via a Kubernetes Catalog entry

Results: See above.

Expected: In all scenarios, expect the ConfigMap to be created with the specified key(s)/value(s).

soumyalj commented 8 years ago

Verified in v1.2.0-pre1-rc1.

configmap specified above was added through UI.

> kubectl describe configmap config-puppetserver-standalone                                                             
Name:           config-puppetserver-standalone                                                                          
Namespace:      default                                                                                                 
Labels:         <none>                                                                                                  
Annotations:    <none>                                                                                                  

Data                                                                                                                    
====                                                                                                                    
controlrepo.git.uri:    35 bytes        
> kubectl get configmap config-puppetserver-standalone -o yaml                                                          
apiVersion: v1                                                                                                          
data:                                                                                                                   
  controlrepo.git.uri: from cm-puppetserver-standalone.yml                                                              
kind: ConfigMap                                                                                                         
metadata:                                                                                                               
  creationTimestamp: 2016-07-20T23:43:43Z                                                                               
  name: config-puppetserver-standalone                                                                                  
  namespace: default                                                                                                    
  resourceVersion: "845"                                                                                                
  selfLink: /api/v1/namespaces/default/configmaps/config-puppetserver-standalone                                        
  uid: cb0e9c04-4ed3-11e6-ad46-0212b8815492