X-Git-Url: https://gerrit.akraino.org/r/gitweb?a=blobdiff_plain;f=ansible%2Froles%2Fswift%2Ftemplates%2Fupdate%2Fswift_update.yml;h=3f243464916702f0dc7c433c1baf150c1acf00d2;hb=85d00249cd7fd51320c736851b40844bb54fbd3c;hp=8f6f9403820fd2e7e49186b79436f8ae4c8174f1;hpb=2ed671c54dad28dd81763928b28cd17d5c76df66;p=ta%2Fcaas-registry.git diff --git a/ansible/roles/swift/templates/update/swift_update.yml b/ansible/roles/swift/templates/update/swift_update.yml index 8f6f940..3f24346 100644 --- a/ansible/roles/swift/templates/update/swift_update.yml +++ b/ansible/roles/swift/templates/update/swift_update.yml @@ -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: DaemonSet metadata: name: swift-update @@ -28,10 +28,16 @@ spec: labels: name: swift-update spec: + priorityClassName: "system-cluster-critical" hostNetwork: true dnsPolicy: ClusterFirstWithHostNet nodeSelector: - nodename: caas_master1 + nodetype: caas_master + tolerations: + - key: "node-maintenancemode" + value: "enabled" + operator: "Equal" + effect: "NoExecute" securityContext: runAsUser: {{ caas.uid.swift }} containers: @@ -39,13 +45,14 @@ spec: image: {{ container_image_names | select('search', '/swift') | list | last }} securityContext: capabilities: - add: ["NET_BIND_SERVICE"] + add: ["NET_BIND_SERVICE", "SETGID", "SETUID"] args: - BACKEND resources: limits: memory: "4Gi" requests: + cpu: "200m" memory: "1Gi" env: - name: "SWIFT_PART_POWER" @@ -58,6 +65,8 @@ spec: value: "1" - name: "SWIFT_OAM1_IP" value: "{{ hostvars[groups.caas_master[0]]['networking']['infra_internal']['ip'] }}" + - name: "SWIFT_URL" + value: "{{ caas.swift }}" volumeMounts: - name: config mountPath: /etc/swift/