- support alpha deploy.
This commit is contained in:
@@ -5,16 +5,16 @@
|
||||
- name: copy shell
|
||||
copy:
|
||||
src: ../deploy/cleanup.sh
|
||||
dest: /jxdata/jx-callback/cleanup.sh
|
||||
dest: "{{ deploy_dir }}/cleanup.sh"
|
||||
owner: ubuntu
|
||||
group: ubuntu
|
||||
mode: 0777
|
||||
- name: cleanup previous backup files
|
||||
shell: cd /jxdata/jx-callback && ./cleanup.sh
|
||||
shell: cd {{ deploy_dir }} && ./cleanup.sh
|
||||
- name: copy execute file to dest
|
||||
copy:
|
||||
src: ../jx-callback
|
||||
dest: /jxdata/jx-callback/jx-callback
|
||||
dest: "{{ deploy_dir }}/jx-callback"
|
||||
owner: ubuntu
|
||||
group: ubuntu
|
||||
mode: 0755
|
||||
@@ -22,17 +22,22 @@
|
||||
- name: copy conf file to dest
|
||||
copy:
|
||||
src: ../conf/app.conf
|
||||
dest: /jxdata/jx-callback/conf/app.conf
|
||||
dest: "{{ deploy_dir }}/conf/app.conf"
|
||||
owner: ubuntu
|
||||
group: ubuntu
|
||||
mode: 0555
|
||||
- name: copy swagger files to dest
|
||||
copy:
|
||||
src: ../swagger
|
||||
dest: /jxdata/jx-callback/
|
||||
dest: "{{ deploy_dir }}/"
|
||||
owner: ubuntu
|
||||
group: ubuntu
|
||||
mode: 0555
|
||||
|
||||
- name: shell
|
||||
shell: cd /jxdata/jx-callback/conf && sed -i 's/runmode\s*=\s*.*/runmode = {{ runmode }}/' app.conf && sudo systemctl restart jx-callback
|
||||
shell: cd {{ deploy_dir }}/conf && sed -i 's/runmode\s*=\s*.*/runmode = {{ runmode }}/' app.conf && sudo systemctl restart jx-callback
|
||||
when: runmode == "prod"
|
||||
|
||||
- name: shell
|
||||
shell: cd {{ deploy_dir }}/conf && sed -i 's/runmode\s*=\s*.*/runmode = {{ runmode }}/' app.conf && sudo systemctl restart jx-callback-{{ runmode }}
|
||||
when: runmode != "prod"
|
||||
|
||||
Reference in New Issue
Block a user