Aptomi / k8s-app-engine

Application delivery engine for k8s
Apache License 2.0
163 stars 19 forks source link

If old Helm chart and current cluster have different namespaces, Aptomi fails with an error #232

Closed romangithub1024 closed 6 years ago

romangithub1024 commented 6 years ago

Steps to reproduce: 1) Deploy services in "east" 2) Delete namespace "east" via kubectl (but keep Helm charts) 3) Import another cluster "eastnew" 4) Change rule to deploy to "eastnew" 5) Re-deploy app

time="2018-02-04T07:07:26Z" level=error msg="(enforce-52-apply) error while applying action 'action-component-create/cluster-us-east#main#zookeeper#prod#zookeeper': error while creating component 'cluster-us-east#main#zookeeper#prod#zookeeper': rpc error: code = Unknown desc = failed to create resource: namespaces "east" not found"

We should check if namespaces don't match (may be there is something else that won't match?!). If they don't, we should either throw an error or delete/create the release.