Commit efeb13be by ansible

no message

1 parent d7cfcd03
---
- hosts: dhipaya-prd
become: true
vars:
dmapublishURL: 'publishUrl = https://tipeasy.dhipaya.co.th'
wdchatpublishURL: https://tipsocial.dhipaya.co.th
updateURL: https://tipsocial.dhipaya.co.th:444/index.html
dmaserverName: 'server_name tipeasy.dhipaya.co.th;'
wdchatserverName: 'server_name tipsocial.dhipaya.co.th;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- name: Update Customer WDCHAT Theme
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/tipsocial/wdchat_theme.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Deploy Customer iChatWeb.war
command: cp /tmp/tipsocial/iChatWeb.war /opt/stack/runtime/wildfly/standalone/deployments/iChatWeb.war
- hosts: dhipaya-dev
become: true
vars:
dmapublishURL: 'publishUrl = https://tipeasydev.dhipaya.co.th'
wdchatpublishURL: https://tipsocialdev.dhipaya.co.th
updateURL: https://tipsocialdev.dhipaya.co.th:444/index.html
dmaserverName: 'server_name tipeasydev.dhipaya.co.th;'
wdchatserverName: 'server_name ;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- hosts: blueprint
become: true
vars:
dmapublishURL: 'publishUrl = https://bpdma.beebuddy.net'
wdchatpublishURL: https://bpchat.beebuddy.net
updateURL: https://bpchat.beebuddy.net:444/index.html
dmaserverName: 'server_name bpdma.beebuddy.net;'
wdchatserverName: 'server_name bpchat.beebuddy.net;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- name: Update Theme
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/blueprint/wdchat_theme.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Deploy Customer iChatWeb.war
command: cp /tmp/blueprint/iChatWeb.war /opt/stack/runtime/wildfly/standalone/deployments/iChatWeb.war
- hosts: beebuddy
become: true
vars:
dmapublishURL: 'publishUrl = https://bbdma.beebuddy.net'
wdchatpublishURL: https://bbchat.beebuddy.net
updateURL: https://bbchat.beebuddy.net:444/index.html
dmaserverName: 'server_name bbdma.beebuddy.net;'
wdchatserverName: 'server_name bbchat.beebuddy.net;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- name: Update Theme
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/beebuddy/wdchat_theme.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Deploy Customer iChatWeb.war
command: cp /tmp/beebuddy/iChatWeb.war /opt/stack/runtime/wildfly/standalone/deployments/iChatWeb.war
- hosts: ptychat
become: true
vars:
dmapublishURL: 'publishUrl = https://'
wdchatpublishURL: https://pty-chat.partsoto.net:4433
updateURL: https://pty-chat.partsoto.net:444/index.html
dmaserverName: 'server_name ;'
wdchatserverName: 'server_name pty-chat.partsoto.net;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- name: Update Theme
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/ptychat/wdchat_theme.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Deploy Customer iChatWeb.war
command: cp /tmp/ptychat/iChatWeb.war /opt/stack/runtime/wildfly/standalone/deployments/iChatWeb.war
- hosts: scgchat
become: true
vars:
dmapublishURL: 'publishUrl = https://;'
wdchatpublishURL: https://scgchat.beebuddy.net
updateURL: https://scgchat.beebuddy.net:444/index.html
dmaserverName: 'server_name ;'
wdchatserverName: 'server_name scgchat.beebuddy.net;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- name: Update Theme
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/scgchat/wdchat_theme.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Deploy Customer iChatWeb.war
command: cp /tmp/scgchat/iChatWeb.war /opt/stack/runtime/wildfly/standalone/deployments/iChatWeb.war
- name: Deploy Customer iChatGateway.war
command: cp /tmp/scgchat/iChatGateway.war /opt/stack/runtime/wildfly/standalone/deployments/iChatGateway.war
- hosts: dmadev-singlehost
become: true
vars:
dmapublishURL: 'publishUrl = https://dma2.beebuddy.net'
wdchatpublishURL: https://dma2.beebuddy.net
updateURL: https://dma2.beebuddy.net:444/index.html
dmaserverName: 'server_name dma2.beebuddy.net;'
wdchatserverName: 'server_name ;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- hosts: dmasit-singlehost
become: true
vars:
dmapublishURL: 'publishUrl = https://dmasit2.beebuddy.net'
wdchatpublishURL: https://dmasit2.beebuddy.net
updateURL: https://dmasit2.beebuddy.net:444/index.html
dmaserverName: 'server_name dmasit2.beebuddy.net;'
wdchatserverName: 'server_name ;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- hosts: wdchatdev
become: true
vars:
dmapublishURL: 'publishUrl = https://;'
wdchatpublishURL: https://wdchatdev.beebuddy.net
updateURL: https://wdchatdev.beebuddy.net:444/index.html
dmaserverName: 'server_name ;'
wdchatserverName: 'server_name wdchatdev.beebuddy.net;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- name: Update Theme
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/default/wdchat_theme.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Deploy Customer iChatWeb.war
command: cp /tmp/default/iChatWeb.war /opt/stack/runtime/wildfly/standalone/deployments/iChatWeb.war
- hosts: wdchatsit
become: true
vars:
dmapublishURL: 'publishUrl = https://;'
wdchatpublishURL: https://wdchatsit.beebuddy.net
updateURL: https://wdchatsit.beebuddy.net:444/index.html
dmaserverName: 'server_name ;'
wdchatserverName: 'server_name wdchatsit.beebuddy.net;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- name: Update Theme
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/default/wdchat_theme.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Deploy Customer iChatWeb.war
command: cp /tmp/default/iChatWeb.war /opt/stack/runtime/wildfly/standalone/deployments/iChatWeb.war
- hosts: deves.prd
become: true
vars:
dmapublishURL: 'publishUrl = https://myDEVES.deves.co.th'
wdchatpublishURL: https://myDEVES.deves.co.th
updateURL: https://myDEVES.deves.co.th:444/index.html
dmaserverName: 'server_name myDEVES.deves.co.th;'
wdchatserverName: 'server_name ;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- hosts: deves.dev
become: true
vars:
dmapublishURL: 'publishUrl = https://myDEVESuat.deves.co.th'
wdchatpublishURL: https://myDEVESuat.deves.co.th
updateURL: https://myDEVESuat.deves.co.th:444/index.html
dmaserverName: 'server_name myDEVESuat.deves.co.th;'
wdchatserverName: 'server_name ;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- hosts: sale.beebuddy.net
become: true
vars:
dmapublishURL: 'publishUrl = https://sale.beebuddy.net'
wdchatpublishURL: https://sale.beebuddy.net
updateURL: https://sale.beebuddy.net:444/index.html
dmaserverName: 'server_name sale.beebuddy.net;'
wdchatserverName: 'server_name ;'
hostName: saledemo
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine saledemo'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- hosts: scgdma.beebuddy.net
become: true
vars:
dmapublishURL: 'publishUrl = https://scgdma.beebuddy.net'
wdchatpublishURL: https://scgdma.beebuddy.net
updateURL: https://scgdma.beebuddy.net:444/index.html
dmaserverName: 'server_name scgdma.beebuddy.net;'
wdchatserverName: 'server_name ;'
hostName: scgdemo
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine scgdemo'
tasks:
- file:
path: /opt/stack/dma/conf/dmaconfig.properties
state: touch
mode: 0644
- name: Update DMA publish URL
copy: content="{{ dmapublishURL }}" dest=/opt/stack/dma/conf/dmaconfig.properties
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
- hosts: wdchat.beebuddy.net
become: true
vars:
dmapublishURL: 'publishUrl = https://wdchat.beebuddy.net'
wdchatpublishURL: https://wdchat.beebuddy.net
updateURL: https://wdchat.beebuddy.net:444/index.html
dmaserverName: 'server_name wdchat.beebuddy.net;'
wdchatserverName: 'server_name wdchat.beebuddy.net;'
hostName: wdchat
etcHost: '127.0.0.1 wdchatgateway localhost wdchatengine wdchat'
tasks:
- name: Update NginX DMA server name
copy: content="{{ dmaserverName }}" dest=/opt/stack/nginx/conf/dmadomain.conf
- name: Update NginX WDCHAT server name
copy: content="{{ wdchatserverName }}" dest=/opt/stack/nginx/conf/wdchatdomain.conf
- name: Update publish url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ wdchatpublishURL }}' where sys_group ='system' and sys_key = 'publish_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Update application download url
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -c "update wd_sys_config set sys_value = '{{ updateURL }}' where sys_group ='appversion' and sys_key = 'update_url'"
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Configure hostname
hostname: name={{ hostName }}
- name: Configure /etc/hosts
lineinfile:
path: /etc/hosts
regexp: '^127\.0\.0\.1'
line: "{{ etcHost }}"
owner: root
group: root
mode: 0644
---
- hosts: 06_deploy-defalut-ntp
become: true
tasks:
- name: Deploy NTP Configuration
command: cp /tmp/configuration/ntp.conf /etc/ntp.conf
- name: Restart NTP service
command: systemctl restart ntp.service
\ No newline at end of file
---
- hosts: 06_deploy-defalut-certificate
become: true
tasks:
- name: Deploy Server Certificate File
command: cp /tmp/configuration/beebuddy.ssl/server.crt /opt/stack/nginx/conf/ssl/server.crt
- name: Deploy Server Key File
command: cp /tmp/configuration/beebuddy.ssl/server.key /opt/stack/nginx/conf/ssl/server.key
\ No newline at end of file
---
- hosts: 07_patch-dma-3.0.3
become: true
tasks:
- name: Deploy ims-1.0.0
command: cp /tmp/application/ims-1.0.0.war /opt/stack/runtime/wildfly/standalone/deployments/ims.war
- name: Deploy jsb.war
command: cp /tmp/application/jsb.war /opt/stack/admin/wildfly/standalone/deployments/jsb.war
- hosts: 07_patch-dma-3.0.5
become: true
tasks:
- name: Deploy iChat-3.0.5
command: cp /tmp/application/iChat-1.1.1.war /opt/stack/runtime/wildfly/standalone/deployments/iChat.war
- name: Deploy serviceGateway-3.1.3
command: cp /tmp/application/serviceGateway-3.1.3.war /opt/stack/runtime/wildfly/standalone/deployments/serviceGateway.war
- name: Deploy dmaManager-3.0.5
command: cp /tmp/application/dmaManager-3.0.5.war /opt/stack/runtime/wildfly/standalone/deployments/dmaManager.war
- name: Deploy dmaEngine-3.0.5
command: cp /tmp/application/dmaEngine-3.0.5.war /opt/stack/runtime/wildfly/standalone/deployments/dmaEngine.war
- name: Deploy ims-1.0.0
command: cp /tmp/application/ims-1.0.0.war /opt/stack/runtime/wildfly/standalone/deployments/ims.war
- name: Deploy jsb
command: cp /tmp/application/jsb.war /opt/stack/admin/wildfly/standalone/deployments/jsb.war
- name: Deploy iConsole-3.0.6.0
command: cp /tmp/application/iConsole-3.0.6.0.war /opt/stack/admin/wildfly/standalone/deployments/iConsole.war
- hosts: 07_patch-dma-3.0.6
become: true
tasks:
- name: Deploy iChat-3.0.5
command: cp /tmp/application/iChat-1.1.1.war /opt/stack/runtime/wildfly/standalone/deployments/iChat.war
- name: Deploy serviceGateway-3.1.3
command: cp /tmp/application/serviceGateway-3.1.3.war /opt/stack/runtime/wildfly/standalone/deployments/serviceGateway.war
- name: Deploy dmaManager-3.0.6.0
command: cp /tmp/application/dmaManager-3.0.6.0.war /opt/stack/runtime/wildfly/standalone/deployments/dmaManager.war
- name: Deploy dmaEngine-3.0.5
command: cp /tmp/application/dmaEngine-3.0.5.war /opt/stack/runtime/wildfly/standalone/deployments/dmaEngine.war
- name: Deploy ims-1.0.0
command: cp /tmp/application/ims-1.0.0.war /opt/stack/runtime/wildfly/standalone/deployments/ims.war
- name: Deploy jsb
command: cp /tmp/application/jsb.war /opt/stack/admin/wildfly/standalone/deployments/jsb.war
- name: Deploy iConsole-3.0.6.0
command: cp /tmp/application/iConsole-3.0.6.0.war /opt/stack/admin/wildfly/standalone/deployments/iConsole.war
- hosts: 07_patch-dma-3.1.0
become: true
tasks:
- name: Deploy iChat-3.0.5
command: cp /tmp/application/iChat-1.1.1.war /opt/stack/runtime/wildfly/standalone/deployments/iChat.war
- name: Deploy serviceGateway-3.1.3
command: cp /tmp/application/serviceGateway-3.1.3.war /opt/stack/runtime/wildfly/standalone/deployments/serviceGateway.war
- name: Deploy dmaManager-3.1.0.0
command: cp /tmp/application/dmaManager-3.1.0.0.war /opt/stack/runtime/wildfly/standalone/deployments/dmaManager.war
- name: Deploy dmaEngine-3.0.5
command: cp /tmp/application/dmaEngine-3.0.5.war /opt/stack/runtime/wildfly/standalone/deployments/dmaEngine.war
- name: Deploy ims-1.0.0
command: cp /tmp/application/ims-1.0.0.war /opt/stack/runtime/wildfly/standalone/deployments/ims.war
- name: Deploy jsb
command: cp /tmp/application/jsb.war /opt/stack/admin/wildfly/standalone/deployments/jsb.war
- name: Deploy iConsole-3.0.6.0
command: cp /tmp/application/iConsole-3.0.6.0.war /opt/stack/admin/wildfly/standalone/deployments/iConsole.war
- hosts: 07_patch-dma-3.1.2
become: true
tasks:
- name: Deploy iChat-3.0.5
command: cp /tmp/application/iChat-1.1.1.war /opt/stack/runtime/wildfly/standalone/deployments/iChat.war
- name: Deploy serviceGateway-3.1.6.0
command: cp /tmp/application/serviceGateway-3.1.6.0.war /opt/stack/runtime/wildfly/standalone/deployments/serviceGateway.war
- name: Deploy dmaManager-3.0.6.0
command: cp /tmp/application/dmaManager-3.1.2.0.war /opt/stack/runtime/wildfly/standalone/deployments/dmaManager.war
- name: Deploy dmaEngine-3.0.5
command: cp /tmp/application/dmaEngine-3.0.5.war /opt/stack/runtime/wildfly/standalone/deployments/dmaEngine.war
- name: Deploy ims-1.0.0
command: cp /tmp/application/ims-1.0.0.war /opt/stack/runtime/wildfly/standalone/deployments/ims.war
- name: Deploy jsb
command: cp /tmp/application/jsb.war /opt/stack/admin/wildfly/standalone/deployments/jsb.war
- name: Deploy iConsole-3.0.6.0
command: cp /tmp/application/iConsole-3.0.6.0.war /opt/stack/admin/wildfly/standalone/deployments/iConsole.war
- hosts: 07_patch-dma-3.1.4
become: true
tasks:
- name: Deploy iChat-3.0.5
command: cp /tmp/application/iChat-1.1.1.war /opt/stack/runtime/wildfly/standalone/deployments/iChat.war
- name: Deploy serviceGateway-3.1.7.0
command: cp /tmp/application/serviceGateway-3.1.7.0.war /opt/stack/runtime/wildfly/standalone/deployments/serviceGateway.war
- name: Deploy dmaManager-3.1.4.0
command: cp /tmp/application/dmaManager-3.1.4.0.war /opt/stack/runtime/wildfly/standalone/deployments/dmaManager.war
- name: Deploy dmaEngine-3.0.5
command: cp /tmp/application/dmaEngine-3.0.5.war /opt/stack/runtime/wildfly/standalone/deployments/dmaEngine.war
- name: Deploy ims-1.0.0
command: cp /tmp/application/ims-1.0.0.war /opt/stack/runtime/wildfly/standalone/deployments/ims.war
- name: Deploy jsb
command: cp /tmp/application/jsb.war /opt/stack/admin/wildfly/standalone/deployments/jsb.war
- name: Deploy iConsole-3.0.6.0
command: cp /tmp/application/iConsole-3.0.6.0.war /opt/stack/admin/wildfly/standalone/deployments/iConsole.war
- hosts: 07_patch-dma-3.1.8
become: true
tasks:
- name: Deploy iChat-1.1.3
command: cp /tmp/application/iChat-1.1.3.war /opt/stack/runtime/wildfly/standalone/deployments/iChat.war
- name: Deploy serviceGateway-3.1.8.4
command: cp /tmp/application/serviceGateway-3.1.8.4.war /opt/stack/runtime/wildfly/standalone/deployments/serviceGateway.war
- name: Deploy dmaManager-3.1.8
command: cp /tmp/application/dmaManager-3.1.8.0.war /opt/stack/runtime/wildfly/standalone/deployments/dmaManager.war
- name: Deploy dmaEngine-3.0.7
command: cp /tmp/application/dmaEngine-3.0.7.war /opt/stack/runtime/wildfly/standalone/deployments/dmaEngine.war
- name: Deploy ims-1.0.6
command: cp /tmp/application/ims-1.0.6.war /opt/stack/runtime/wildfly/standalone/deployments/ims.war
- name: Deploy jsb
command: cp /tmp/application/jsb.war /opt/stack/admin/wildfly/standalone/deployments/jsb.war
- name: Deploy iConsole-3.0.6.0
command: cp /tmp/application/iConsole-3.0.6.0.war /opt/stack/admin/wildfly/standalone/deployments/iConsole.war
\ No newline at end of file
---
- hosts: 06_deployed-iConsole-two-host
become: true
tasks:
- name: Copy iConsole
command: cp /tmp/source/iConsole.tar.gz /opt/stack/iConsole.tar.gz
- name: Extract root
command: tar -zxvf /opt/stack/iConsole.tar.gz -C /opt/
- name: Delete File
command: rm /opt/stack/iConsole.tar.gz
- name: Setup Schedule
command: /opt/Schedule/add_schedule
- hosts: 06_deploy-iConsole-single-host
become: true
tasks:
- name: Copy iConsole
command: cp /tmp/source/iConsole.singlehost.dma.tar.gz /opt/stack/iConsole.singlehost.dma.tar.gz
- name: Extract root
command: tar -zxvf /opt/stack/iConsole.singlehost.dma.tar.gz -C /opt/
- name: Delete File
command: rm /opt/stack/iConsole.singlehost.dma.tar.gz
- name: Setup Schedule
command: /opt/Schedule/add_schedule
- hosts: 06_deploy-iConsole-single-host-3.0.6.0
become: true
tasks:
- name: Unarchive a file that is already on the remote machine
unarchive:
src: /tmp/source/iConsole.singlehost.dma.3.0.6.0.zip
dest: /opt
remote_src: yes
group: wdadmin
owner: wdadmin
mode: 0755
- file:
path: '/opt/{{ item.dir }}'
group: wdadmin
owner: wdadmin
mode: 0755
state: directory
recurse: yes
with_items:
- { dir: 'Accessor' }
- { dir: 'iConsole' }
- { dir: 'json' }
- { dir: 'Schedule' }
- name: Setup Schedule
command: /opt/Schedule/add_schedule
\ No newline at end of file
---
- hosts: 06_deploy-wdchat-postgresql-302
become: true
tasks:
- name: Create Database WDCHAT & WDAUTHEN & USER
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=postgres -f /tmp/configuration/0_Create.User.sql
responses:
'Password for user postgres': 'password'
- name: Create WDCHAT Table
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/configuration/1_Create.WDCHAT.Table.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Initial WDCHAT
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/configuration/2_Initial.WDCHAT.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Create WDAUTHEN Table
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdauthen -d WDAUTHEN -f /tmp/configuration/3_Create.WDAUTHEN.Table.sql
responses:
'Password for user wdauthen': 'BBEcLWu5Cdzy3aeH'
- name: Initial WDAUTHEN
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdauthen -d WDAUTHEN -f /tmp/configuration/4_Initial.WDAUTHEN.sql
responses:
'Password for user wdauthen': 'BBEcLWu5Cdzy3aeH'
- hosts: 06_deploy-dma-postgresql-302, 06_deploy-dma-postgresql-312
become: true
tasks:
- name: Create Database WDCHAT
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=postgres -f /tmp/configuration/0_Create.User.sql
responses:
'Password for user postgres': 'password'
- name: Create WDCHAT Table
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/configuration/1_Create.WDCHAT.Table.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Create DMA Table
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/configuration/Create.DMA.Table.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
- name: Initial WDCHAT
expect:
command: /opt/stack/postgres/postgresql/bin/psql --host=127.0.0.1 --port=7432 --username=wdchat -d WDCHAT -f /tmp/configuration/2_Initial.WDCHAT.sql
responses:
'Password for user wdchat': 'BBRyAPNh6g4H9qte'
\ No newline at end of file
---
- hosts: 06_deploy-dma-mongo-302
become: true
tasks:
- name: Insert Initial Data for DMAMANAGER 7018
command: /tmp/configuration/update_dmamanager.sh
- name: Insert Initial Data for SERVICEGATEWAY 7019
command: /tmp/configuration/update_servicegateway.sh
- hosts: 06_deploy-dma-mongo-305
become: true
tasks:
- name: Insert Initial Data for DMAMANAGER 7018
command: /tmp/configuration/update_dmamanager_305.sh
- name: Insert Initial Data for SERVICEGATEWAY 7019
command: /tmp/configuration/update_servicegateway_313.sh
- hosts: 06_deploy-dma-mongo-306
become: true
tasks:
- name: Insert Initial Data for DMAMANAGER 7018
command: /tmp/configuration/update_dmamanager_306.sh
- name: Insert Initial Data for SERVICEGATEWAY 7019
command: /tmp/configuration/update_servicegateway_313.sh
- hosts: 06_deploy-dma-mongo-314
become: true
tasks:
- name: Insert Initial Data for DMAMANAGER 7018
command: /tmp/configuration/update_dmamanager_314.sh
- name: Insert Initial Data for SERVICEGATEWAY 7019
command: /tmp/configuration/update_servicegateway_313.sh
---
- hosts: 06_deploy-dma-mongo-newdatabase-newuser-302
become: true
tasks:
- name: Create User & Database for WDCHAT 7017
command: /tmp/source/mongo_7017.sh
- name: Create User & Database for DMAMANAGER 7018
command: /tmp/source/mongo_7018.sh
- name: Create User & Database for SERVICEGATEWAY 7019
command: /tmp/source/mongo_7019.sh
- name: Create User & Database for DMAENGINE 7020
command: /tmp/source/mongo_7020.sh
- hosts: 06_deploy-dma-mongo-newdatabase-newuser-306
become: true
tasks:
- name: Create User & Database for WDCHAT 7017
command: /tmp/source/mongo_7017.sh
- name: Create User & Database for DMAMANAGER 7018
command: /tmp/source/mongo_7018.sh
- name: Create User & Database for SERVICEGATEWAY 7019
command: /tmp/source/mongo_7019.sh
- hosts: 06_deploy-wdchat-mongo-newdatabase-newuser-302
become: true
tasks:
- name: Create User & Database for WDCHAT 7017
command: /tmp/source/mongo_7017.sh
\ No newline at end of file
---
- hosts: 06_deploy-security-file
become: true
tasks:
- name: Copy root
command: cp /tmp/source/root.tar.gz /root/root.tar.gz
- name: Extract root
command: tar -zxvf /root/root.tar.gz -C /root/
- name: Delete File
command: rm /root/root.tar.gz
- name: Gen License Request File
command: /root/bin/gen_license_request.py
args:
chdir: /root/bin
- name: Gen License File
command: /root/bin/gen_license.py /root/bin/request_license.txt /root/bin/license
- name: Activate License
command: cp /root/bin/license.enc /opt/iConsole/security/wdchat.license
- name: Delete request_license.txt File
command: rm /root/bin/request_license.txt
- name: Delete license.enc File
command: rm /root/bin/license.enc
---
- hosts: 06_deploy-dma-singlehost-script
become: true
tasks:
- name: Copy Script
command: cp /tmp/source/script.singlehost.tar.gz /opt/stack/script.singlehost.tar.gz
- name: Extract Script
command: tar -zxvf /opt/stack/script.singlehost.tar.gz -C /opt/stack/
- name: Delete File
command: rm /opt/stack/script.singlehost.tar.gz
- hosts: 06_deploy-dma-singlehost-script-3.1.4
become: true
tasks:
- name: Unarchive a file that is already on the remote machine
unarchive:
src: /tmp/source/stackscript.singlehost.zip
dest: /opt/stack
remote_src: yes
group: wdadmin
owner: wdadmin
mode: 0711
- file:
path: '/opt/stack/{{ item.dir }}'
group: wdadmin
owner: wdadmin
mode: 0755
state: directory
recurse: yes
with_items:
- { dir: 'script' }
---
- hosts: 06_deploy-dma-as-service
become: true
tasks:
- name: Add Engine Service
command: /opt/stack/script/add_service.sh /opt/stack/script/engine.service
- name: Add Tcp Service
command: /opt/stack/script/add_service.sh /opt/stack/script/nginx.tcp.service
\ No newline at end of file
---
- hosts: 06_patch-wdchat-302
become: true
tasks:
- name: Deploy iChat-1.1.1.war
command: cp /tmp/application/iChat-1.1.1.war /opt/stack/runtime/wildfly/standalone/deployments/iChat-1.1.1.war
- name: Deploy ExAuthenWS.war
command: cp /tmp/application/ExAuthenWS.war /opt/stack/runtime/wildfly/standalone/deployments/ExAuthenWS.war
- name: Deploy iAuthen-1.1.1.war
command: cp /tmp/application/iAuthen-1.1.1.war /opt/stack/runtime/wildfly/standalone/deployments/iAuthen-1.1.1.war
- name: Deploy iChatGateway.war
command: cp /tmp/application/iChatGateway.war /opt/stack/runtime/wildfly/standalone/deployments/iChatGateway.war
- name: Deploy iChatManagement-1.1.1.war
command: cp /tmp/application/iChatManagement-1.1.1.war /opt/stack/admin/wildfly/standalone/deployments/iChatManagement-1.1.1.war
- name: Deploy iConsole.war
command: cp /tmp/application/iConsole.war /opt/stack/admin/wildfly/standalone/deployments/iConsole.war
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!