update element section
This commit is contained in:
parent
8ff0ae27b8
commit
53f4b84d1f
|
@ -32,10 +32,10 @@
|
||||||
"required": false,
|
"required": false,
|
||||||
"min": 0,
|
"min": 0,
|
||||||
"max": 256,
|
"max": 256,
|
||||||
"default": "{{ matrix_client_element_brand }}",
|
"default": "{{ awx_matrix_client_element_brand }}",
|
||||||
"choices": "",
|
"choices": "",
|
||||||
"new_question": true,
|
"new_question": true,
|
||||||
"variable": "matrix_client_element_brand",
|
"variable": "awx_matrix_client_element_brand",
|
||||||
"type": "text"
|
"type": "text"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -44,10 +44,10 @@
|
||||||
"required": false,
|
"required": false,
|
||||||
"min": 0,
|
"min": 0,
|
||||||
"max": 1024,
|
"max": 1024,
|
||||||
"default": "{{ matrix_client_element_branding_welcomeBackgroundUrl }}",
|
"default": "{{ awx_matrix_client_element_branding_welcomeBackgroundUrl }}",
|
||||||
"choices": "",
|
"choices": "",
|
||||||
"new_question": true,
|
"new_question": true,
|
||||||
"variable": "matrix_client_element_branding_welcomeBackgroundUrl",
|
"variable": "awx_matrix_client_element_branding_welcomeBackgroundUrl",
|
||||||
"type": "text"
|
"type": "text"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -56,10 +56,10 @@
|
||||||
"required": false,
|
"required": false,
|
||||||
"min": 0,
|
"min": 0,
|
||||||
"max": 1024,
|
"max": 1024,
|
||||||
"default": "{{ matrix_client_element_welcome_logo }}",
|
"default": "{{ awx_matrix_client_element_welcome_logo }}",
|
||||||
"choices": "",
|
"choices": "",
|
||||||
"new_question": true,
|
"new_question": true,
|
||||||
"variable": "matrix_client_element_welcome_logo",
|
"variable": "awx_matrix_client_element_welcome_logo",
|
||||||
"type": "text"
|
"type": "text"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -68,10 +68,10 @@
|
||||||
"required": false,
|
"required": false,
|
||||||
"min": 0,
|
"min": 0,
|
||||||
"max": 1024,
|
"max": 1024,
|
||||||
"default": "{{ matrix_client_element_welcome_logo_link }}",
|
"default": "{{ awx_matrix_client_element_welcome_logo_link }}",
|
||||||
"choices": "",
|
"choices": "",
|
||||||
"new_question": true,
|
"new_question": true,
|
||||||
"variable": "matrix_client_element_welcome_logo_link",
|
"variable": "awx_matrix_client_element_welcome_logo_link",
|
||||||
"type": "text"
|
"type": "text"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -80,10 +80,10 @@
|
||||||
"required": false,
|
"required": false,
|
||||||
"min": 0,
|
"min": 0,
|
||||||
"max": 512,
|
"max": 512,
|
||||||
"default": "{{ matrix_client_element_welcome_headline }}",
|
"default": "{{ awx_matrix_client_element_welcome_headline }}",
|
||||||
"choices": "",
|
"choices": "",
|
||||||
"new_question": true,
|
"new_question": true,
|
||||||
"variable": "matrix_client_element_welcome_headline",
|
"variable": "awx_matrix_client_element_welcome_headline",
|
||||||
"type": "text"
|
"type": "text"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -92,10 +92,10 @@
|
||||||
"required": false,
|
"required": false,
|
||||||
"min": 0,
|
"min": 0,
|
||||||
"max": 2048,
|
"max": 2048,
|
||||||
"default": "{{ matrix_client_element_welcome_text }}",
|
"default": "{{ awx_matrix_client_element_welcome_text }}",
|
||||||
"choices": "",
|
"choices": "",
|
||||||
"new_question": true,
|
"new_question": true,
|
||||||
"variable": "matrix_client_element_welcome_text",
|
"variable": "awx_matrix_client_element_welcome_text",
|
||||||
"type": "text"
|
"type": "text"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
|
@ -13,6 +13,21 @@
|
||||||
'matrix_client_element_default_theme': '{{ matrix_client_element_default_theme }}'
|
'matrix_client_element_default_theme': '{{ matrix_client_element_default_theme }}'
|
||||||
'matrix_client_element_registration_enabled': '{{ matrix_client_element_registration_enabled }}'
|
'matrix_client_element_registration_enabled': '{{ matrix_client_element_registration_enabled }}'
|
||||||
|
|
||||||
|
- name: Record Synapse Custom variables locally on AWX
|
||||||
|
delegate_to: 127.0.0.1
|
||||||
|
lineinfile:
|
||||||
|
path: '{{ awx_cached_matrix_vars }}'
|
||||||
|
regexp: "^#? *{{ item.key | regex_escape() }}:"
|
||||||
|
line: "{{ item.key }}: '{{ item.value }}'"
|
||||||
|
insertbefore: '# Element Settings End'
|
||||||
|
with_dict:
|
||||||
|
'awx_matrix_client_element_brand': '{{ awx_matrix_client_element_brand }}'
|
||||||
|
'awx_matrix_client_element_branding_welcomeBackgroundUrl:' '{{ awx_matrix_client_element_branding_welcomeBackgroundUrl }}'
|
||||||
|
'awx_matrix_client_element_welcome_logo': '{{ awx_matrix_client_element_welcome_logo }}'
|
||||||
|
'awx_matrix_client_element_welcome_logo_link': '{{ awx_matrix_client_element_welcome_logo_link }}'
|
||||||
|
'awx_matrix_client_element_welcome_headline': '{{ awx_matrix_client_element_welcome_headline }}'
|
||||||
|
'awx_matrix_client_element_welcome_text': '{{ awx_matrix_client_element_welcome_text }}'
|
||||||
|
|
||||||
- name: Set custom branding locally on AWX
|
- name: Set custom branding locally on AWX
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
lineinfile:
|
lineinfile:
|
||||||
|
@ -21,7 +36,7 @@
|
||||||
line: "{{ item.key }}: '{{ item.value }}'"
|
line: "{{ item.key }}: '{{ item.value }}'"
|
||||||
insertafter: '# Element Settings Start'
|
insertafter: '# Element Settings Start'
|
||||||
with_dict:
|
with_dict:
|
||||||
'matrix_client_element_brand': "{{ matrix_client_element_brand }}"
|
'matrix_client_element_brand': "{{ awx_matrix_client_element_brand }}"
|
||||||
|
|
||||||
- name: Remove custom branding locally on AWX if not defined
|
- name: Remove custom branding locally on AWX if not defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -29,7 +44,7 @@
|
||||||
path: '{{ awx_cached_matrix_vars }}'
|
path: '{{ awx_cached_matrix_vars }}'
|
||||||
regexp: "^matrix_client_element_brand: "
|
regexp: "^matrix_client_element_brand: "
|
||||||
state: absent
|
state: absent
|
||||||
when: matrix_client_element_brand | trim | length == 0
|
when: awx_matrix_client_element_brand | trim | length == 0
|
||||||
|
|
||||||
- name: Set fact for 'https' string
|
- name: Set fact for 'https' string
|
||||||
set_fact:
|
set_fact:
|
||||||
|
@ -43,8 +58,8 @@
|
||||||
line: "{{ item.key }}: '{{ item.value }}'"
|
line: "{{ item.key }}: '{{ item.value }}'"
|
||||||
insertafter: '# Element Settings Start'
|
insertafter: '# Element Settings Start'
|
||||||
with_dict:
|
with_dict:
|
||||||
'matrix_client_element_welcome_logo': '{{ matrix_client_element_welcome_logo }}'
|
'matrix_client_element_welcome_logo': '{{ awx_matrix_client_element_welcome_logo }}'
|
||||||
when: ( awx_https_string in matrix_client_element_welcome_logo ) and ( matrix_client_element_welcome_logo | trim | length > 0 )
|
when: ( awx_https_string in awx_matrix_client_element_welcome_logo ) and ( awx_matrix_client_element_welcome_logo | trim | length > 0 )
|
||||||
|
|
||||||
- name: Remove custom logo locally on AWX if not defined
|
- name: Remove custom logo locally on AWX if not defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -52,7 +67,7 @@
|
||||||
path: '{{ awx_cached_matrix_vars }}'
|
path: '{{ awx_cached_matrix_vars }}'
|
||||||
regexp: "^matrix_client_element_welcome_logo: "
|
regexp: "^matrix_client_element_welcome_logo: "
|
||||||
state: absent
|
state: absent
|
||||||
when: matrix_client_element_welcome_logo | trim | length == 0
|
when: awx_matrix_client_element_welcome_logo | trim | length == 0
|
||||||
|
|
||||||
- name: Set custom logo link locally on AWX if defined
|
- name: Set custom logo link locally on AWX if defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -63,7 +78,7 @@
|
||||||
insertafter: '# Element Settings Start'
|
insertafter: '# Element Settings Start'
|
||||||
with_dict:
|
with_dict:
|
||||||
'matrix_client_element_welcome_logo_link': '{{ matrix_client_element_welcome_logo_link }}'
|
'matrix_client_element_welcome_logo_link': '{{ matrix_client_element_welcome_logo_link }}'
|
||||||
when: ( awx_https_string in matrix_client_element_welcome_logo_link ) and ( matrix_client_element_welcome_logo_link | trim | length > 0 )
|
when: ( awx_https_string in awx_matrix_client_element_welcome_logo_link ) and ( awx_matrix_client_element_welcome_logo_link | trim | length > 0 )
|
||||||
|
|
||||||
- name: Remove custom logo link locally on AWX if not defined
|
- name: Remove custom logo link locally on AWX if not defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -71,7 +86,7 @@
|
||||||
path: '{{ awx_cached_matrix_vars }}'
|
path: '{{ awx_cached_matrix_vars }}'
|
||||||
regexp: "^matrix_client_element_welcome_logo_link: "
|
regexp: "^matrix_client_element_welcome_logo_link: "
|
||||||
state: absent
|
state: absent
|
||||||
when: matrix_client_element_welcome_logo_link | trim | length == 0
|
when: awx_matrix_client_element_welcome_logo_link | trim | length == 0
|
||||||
|
|
||||||
- name: Set custom headline locally on AWX if defined
|
- name: Set custom headline locally on AWX if defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -81,8 +96,8 @@
|
||||||
line: "{{ item.key }}: '{{ item.value }}'"
|
line: "{{ item.key }}: '{{ item.value }}'"
|
||||||
insertafter: '# Element Settings Start'
|
insertafter: '# Element Settings Start'
|
||||||
with_dict:
|
with_dict:
|
||||||
'matrix_client_element_welcome_headline': '{{ matrix_client_element_welcome_headline }}'
|
'matrix_client_element_welcome_headline': '{{ awx_matrix_client_element_welcome_headline }}'
|
||||||
when: matrix_client_element_welcome_headline | trim | length > 0
|
when: awx_matrix_client_element_welcome_headline | trim | length > 0
|
||||||
|
|
||||||
- name: Remove custom headline locally on AWX if not defined
|
- name: Remove custom headline locally on AWX if not defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -90,7 +105,7 @@
|
||||||
path: '{{ awx_cached_matrix_vars }}'
|
path: '{{ awx_cached_matrix_vars }}'
|
||||||
regexp: "^matrix_client_element_welcome_headline: "
|
regexp: "^matrix_client_element_welcome_headline: "
|
||||||
state: absent
|
state: absent
|
||||||
when: matrix_client_element_welcome_headline | trim | length == 0
|
when: awx_matrix_client_element_welcome_headline | trim | length == 0
|
||||||
|
|
||||||
- name: Set custom text locally on AWX if defined
|
- name: Set custom text locally on AWX if defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -100,8 +115,8 @@
|
||||||
line: "{{ item.key }}: '{{ item.value }}'"
|
line: "{{ item.key }}: '{{ item.value }}'"
|
||||||
insertafter: '# Element Settings Start'
|
insertafter: '# Element Settings Start'
|
||||||
with_dict:
|
with_dict:
|
||||||
'matrix_client_element_welcome_text': '{{ matrix_client_element_welcome_text }}'
|
'matrix_client_element_welcome_text': '{{ awx_matrix_client_element_welcome_text }}'
|
||||||
when: matrix_client_element_welcome_text | trim | length > 0
|
when: awx_matrix_client_element_welcome_text | trim | length > 0
|
||||||
|
|
||||||
- name: Remove custom text locally on AWX if not defined
|
- name: Remove custom text locally on AWX if not defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -109,7 +124,7 @@
|
||||||
path: '{{ awx_cached_matrix_vars }}'
|
path: '{{ awx_cached_matrix_vars }}'
|
||||||
regexp: "^matrix_client_element_welcome_text: "
|
regexp: "^matrix_client_element_welcome_text: "
|
||||||
state: absent
|
state: absent
|
||||||
when: matrix_client_element_welcome_text | trim | length == 0
|
when: awx_matrix_client_element_welcome_text | trim | length == 0
|
||||||
|
|
||||||
- name: Set element-web background locally on AWX if defined
|
- name: Set element-web background locally on AWX if defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -119,8 +134,8 @@
|
||||||
line: "{{ item.key }}: '{{ item.value }}'"
|
line: "{{ item.key }}: '{{ item.value }}'"
|
||||||
insertafter: '# Element Settings Start'
|
insertafter: '# Element Settings Start'
|
||||||
with_dict:
|
with_dict:
|
||||||
'matrix_client_element_branding_welcomeBackgroundUrl': '{{ matrix_client_element_branding_welcomeBackgroundUrl }}'
|
'matrix_client_element_branding_welcomeBackgroundUrl': '{{ awx_matrix_client_element_branding_welcomeBackgroundUrl }}'
|
||||||
when: matrix_client_element_branding_welcomeBackgroundUrl | trim | length > 0
|
when: awx_matrix_client_element_branding_welcomeBackgroundUrl | trim | length > 0
|
||||||
|
|
||||||
- name: Remove element-web background locally on AWX if not defined
|
- name: Remove element-web background locally on AWX if not defined
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
@ -128,7 +143,7 @@
|
||||||
path: '{{ awx_cached_matrix_vars }}'
|
path: '{{ awx_cached_matrix_vars }}'
|
||||||
regexp: "^matrix_client_element_branding_welcomeBackgroundUrl: "
|
regexp: "^matrix_client_element_branding_welcomeBackgroundUrl: "
|
||||||
state: absent
|
state: absent
|
||||||
when: matrix_client_element_branding_welcomeBackgroundUrl | trim | length == 0
|
when: awx_matrix_client_element_branding_welcomeBackgroundUrl | trim | length == 0
|
||||||
|
|
||||||
- name: Save new 'Configure Element' survey.json to the AWX tower, template
|
- name: Save new 'Configure Element' survey.json to the AWX tower, template
|
||||||
delegate_to: 127.0.0.1
|
delegate_to: 127.0.0.1
|
||||||
|
|
Loading…
Reference in a new issue