Code Review
/
ta
/
caas-registry.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Add maintenance toleration for caas-registry
[ta/caas-registry.git]
/
ansible
/
roles
/
swift
/
templates
/
main
/
swift_main.yml
diff --git
a/ansible/roles/swift/templates/main/swift_main.yml
b/ansible/roles/swift/templates/main/swift_main.yml
index
bcbf9e8
..
d514e46
100644
(file)
--- a/
ansible/roles/swift/templates/main/swift_main.yml
+++ b/
ansible/roles/swift/templates/main/swift_main.yml
@@
-14,7
+14,7
@@
See the License for the specific language governing permissions and
limitations under the License.
#}
---
limitations under the License.
#}
---
-apiVersion: apps/v1
beta2
+apiVersion: apps/v1
kind: DaemonSet
metadata:
name: swift
kind: DaemonSet
metadata:
name: swift
@@
-28,10
+28,16
@@
spec:
labels:
name: swift
spec:
labels:
name: swift
spec:
+ priorityClassName: "system-cluster-critical"
hostNetwork: true
dnsPolicy: ClusterFirstWithHostNet
nodeSelector:
nodetype: caas_master
hostNetwork: true
dnsPolicy: ClusterFirstWithHostNet
nodeSelector:
nodetype: caas_master
+ tolerations:
+ - key: "node-maintenancemode"
+ value: "enabled"
+ operator: "Equal"
+ effect: "NoExecute"
securityContext:
runAsUser: {{ caas.uid.swift }}
containers:
securityContext:
runAsUser: {{ caas.uid.swift }}
containers:
@@
-39,21
+45,23
@@
spec:
image: {{ container_image_names | select('search', '/swift') | list | last }}
securityContext:
capabilities:
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:
args:
- BACKEND
resources:
limits:
+ cpu: "1"
memory: "4Gi"
requests:
memory: "4Gi"
requests:
+ cpu: "200m"
memory: "1Gi"
env:
- name: "SWIFT_USER"
memory: "1Gi"
env:
- name: "SWIFT_USER"
- value: "{{
swift_user_for_template.stdout
}}"
+ value: "{{
caas.swift_credential.user
}}"
- name: "SWIFT_TENANT"
- name: "SWIFT_TENANT"
- value: "{{
swift_tenant_for_template.stdou
t }}"
+ value: "{{
caas.swift_credential.tenan
t }}"
- name: "SWIFT_PASS"
- name: "SWIFT_PASS"
- value: "{{
swift_password_for_template.stdout
}}"
+ value: "{{
caas.swift_credential.password
}}"
- name: "SWIFT_PART_POWER"
value: "7"
- name: "SWIFT_PART_HOUR"
- name: "SWIFT_PART_POWER"
value: "7"
- name: "SWIFT_PART_HOUR"
@@
-66,6
+74,8
@@
spec:
- name: "SWIFT_OAM{{loop.index}}_IP"
value: "{{ hostvars[host]['networking']['infra_internal']['ip'] }}"
{% endfor %}
- name: "SWIFT_OAM{{loop.index}}_IP"
value: "{{ hostvars[host]['networking']['infra_internal']['ip'] }}"
{% endfor %}
+ - name: "SWIFT_URL"
+ value: "{{ caas.swift }}"
volumeMounts:
- name: config
mountPath: /etc/swift/
volumeMounts:
- name: config
mountPath: /etc/swift/