Update osbs-namespace role with latest upstream
Signed-off-by: Clement Verna <cverna@tutanota.com>
This commit is contained in:
parent
1bb844c9f0
commit
1791fbe385
29 changed files with 493 additions and 38 deletions
|
@ -35,6 +35,9 @@ Role Variables
|
|||
# Then to re-enable node:
|
||||
osbs_enable_node: true
|
||||
|
||||
# Override default systemd unit files
|
||||
osbs_systemd_override: true
|
||||
|
||||
See `operations/defaults/main.yml` for a comprehensive list of all
|
||||
available variables.
|
||||
|
||||
|
|
|
@ -19,6 +19,10 @@ osbs_wait_active_pods_delay: 30 # seconds
|
|||
osbs_wait_node_ready_retries: 30
|
||||
osbs_wait_node_ready_delay: 10
|
||||
|
||||
osbs_buildroot_do_tag: false
|
||||
osbs_buildroot_imagestream_live_tag: ''
|
||||
osbs_buildroot_imagestream: ''
|
||||
osbs_buildroot_imagestream_post_build_tag: ''
|
||||
|
||||
osbs_systemd_override: false
|
||||
osbs_systemd_limit_nofile: 131072
|
||||
|
|
6
roles/osbs-namespace/operations/handlers/main.yml
Normal file
6
roles/osbs-namespace/operations/handlers/main.yml
Normal file
|
@ -0,0 +1,6 @@
|
|||
---
|
||||
- name: restart atomic-openshift-node
|
||||
service:
|
||||
name: atomic-openshift-node
|
||||
state: restarted
|
||||
daemon_reload: yes
|
|
@ -9,7 +9,10 @@
|
|||
when: osbs_update_node_labels
|
||||
|
||||
- include: tag-buildroot.yml
|
||||
when: osbs_buildroot_imagestream_live_tag != ''
|
||||
when: osbs_buildroot_do_tag
|
||||
|
||||
- include: enable-node.yml
|
||||
when: osbs_enable_node
|
||||
|
||||
- include: override-systemd.yml
|
||||
when: osbs_systemd_override
|
||||
|
|
11
roles/osbs-namespace/operations/tasks/override-systemd.yml
Normal file
11
roles/osbs-namespace/operations/tasks/override-systemd.yml
Normal file
|
@ -0,0 +1,11 @@
|
|||
---
|
||||
- name: Set LimitNOFILE in atomic-openshift-node
|
||||
lineinfile:
|
||||
path: /etc/systemd/system/atomic-openshift-node.service
|
||||
regexp: '^LimitNOFILE='
|
||||
line: 'LimitNOFILE={{ osbs_systemd_limit_nofile }}'
|
||||
backup: yes
|
||||
notify:
|
||||
- restart atomic-openshift-node
|
||||
|
||||
- meta: flush_handlers
|
|
@ -2,8 +2,13 @@
|
|||
# Tag the desired build image with the post build tag (“staged” for stage, “released” for prod)
|
||||
- name: tag buildroot imagestream
|
||||
command: >
|
||||
oc tag {{ osbs_buildroot_imagestream }}:{{ osbs_buildroot_imagestream_live_tag }} {{ osbs_buildroot_imagestream }}:{{ osbs_buildroot_imagestream_post_build_tag }}
|
||||
oc tag --namespace={{ osbs_namespace }}
|
||||
{{ osbs_buildroot_imagestream }}:{{ osbs_buildroot_imagestream_live_tag }}
|
||||
{{ osbs_buildroot_imagestream }}:{{ osbs_buildroot_imagestream_post_build_tag }}
|
||||
environment: "{{ osbs_environment }}"
|
||||
when: osbs_buildroot_imagestream != '' and osbs_buildroot_imagestream_live_tag != '' and osbs_buildroot_imagestream_post_build_tag != ''
|
||||
when:
|
||||
- osbs_buildroot_imagestream != ''
|
||||
- osbs_buildroot_imagestream_live_tag != ''
|
||||
- osbs_buildroot_imagestream_post_build_tag != ''
|
||||
tags:
|
||||
- oc
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue