Schedule pods by nodetype
[ta/caas-helm.git] / ansible / roles / chart_repo / templates / chart-repo.yml
index af4f5e8..580adb2 100644 (file)
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
 limitations under the License.
 #}
 ---
-apiVersion: apps/v1beta2
+apiVersion: apps/v1
 kind: Deployment
 metadata:
   name: chart-repo
@@ -26,32 +26,22 @@ spec:
       {{ caas.kubernetes_component_label }}: chart-repo
   template:
     metadata:
-      annotations:
-        danm.k8s.io/interfaces: |
-          [
-            {
-              "network":"flannel"
-            }
-          ]
       labels:
         {{ caas.kubernetes_component_label }}: chart-repo
     spec:
+      priorityClassName: "system-cluster-critical"
       dnsPolicy: ClusterFirst
       nodeSelector:
-        nodename: caas_master1
+        nodetype: caas_master
       securityContext:
         runAsUser: {{ caas.uid.chartrepo }}
       containers:
         - name: chart-repo-handler
           image: {{ container_image_names | select('search', '/chartrepo') | list | last }}
           imagePullPolicy: IfNotPresent
-          ## Limits equals requets to put the container into qualified QoS category
           resources:
-            limits:
-              cpu: "0.2"
-              memory: "128Mi"
             requests:
-              cpu: "0.2"
+              cpu: "10m"
               memory: "128Mi"
           command:
             - "/usr/bin/mainstart.sh"
@@ -65,7 +55,7 @@ spec:
             - name: CHARTREPOHANDLER_LISTENONINTERFACE
               value: "{{ caas.internal_flannel_interface }}"
             - name: CHARTREPOHANDLER_AUTHKEY
-              value: "{{ swift_pass.stdout }}"
+              value: "{{ caas.swift_credential.password }}"
             - name: CHARTREPOHANDLER_CONTAINER
               value: packages
             - name: CHARTREPOHANDLER_REPOURL