deploy/deploy.yml
changeset 1 66f388fa2130
parent 0 5f4fcbc80b37
child 2 f72ffe8b30b1
equal deleted inserted replaced
0:5f4fcbc80b37 1:66f388fa2130
     1 ---
     1 ---
     2 - hosts: all
     2 # - hosts: all
     3   tasks:
     3 #   tasks:
     4     - name: Print some debug information 
     4 #     - name: Print some debug information 
     5       vars: 
     5 #       vars: 
     6         msg: |
     6 #         msg: |
     7             Module Variables ("vars"):
     7 #             Module Variables ("vars"):
     8             --------------------------------
     8 #             --------------------------------
     9             {{ vars | to_nice_json }} 
     9 #             {{ vars | to_nice_json }} 
    10 
    10 
    11             Environment Variables ("environment"):
    11 #             Environment Variables ("environment"):
    12             --------------------------------
    12 #             --------------------------------
    13             {{ environment | to_nice_json }} 
    13 #             {{ environment | to_nice_json }} 
    14 
    14 
    15             GROUP NAMES Variables ("group_names"):
    15 #             GROUP NAMES Variables ("group_names"):
    16             --------------------------------
    16 #             --------------------------------
    17             {{ group_names | to_nice_json }}
    17 #             {{ group_names | to_nice_json }}
    18 
    18 
    19             GROUPS Variables ("groups"):
    19 #             GROUPS Variables ("groups"):
    20             --------------------------------
    20 #             --------------------------------
    21             {{ groups | to_nice_json }}
    21 #             {{ groups | to_nice_json }}
    22 
    22 
    23             HOST Variables ("hostvars"):
    23 #             HOST Variables ("hostvars"):
    24             --------------------------------
    24 #             --------------------------------
    25             {{ hostvars | to_nice_json }} 
    25 #             {{ hostvars | to_nice_json }} 
    26 
    26 
    27       debug: 
    27 #       debug: 
    28         msg: "{{ msg.split('\n') }}"       
    28 #         msg: "{{ msg.split('\n') }}"       
    29       tags: debug_info
    29 #       tags: debug_info
    30 #
    30 #
    31 # Localhost actions
    31 # Localhost actions
    32 #
    32 #
    33 - hosts: localhost
    33 - hosts: localhost
    34   vars_files:
    34   connection: local
    35     - "{{playbook_dir}}/deploy_vars.yml"
       
    36   vars:
    35   vars:
    37     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
    36     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
    38     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
    37     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
    39     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
    38     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
    40   tasks:
    39   tasks:
    99 
    98 
   100 #
    99 #
   101 # all actions
   100 # all actions
   102 #
   101 #
   103 - hosts: remote_discussions
   102 - hosts: remote_discussions
   104   vars_files:
       
   105     - "{{playbook_dir}}/deploy_vars.yml"
       
   106   vars:
   103   vars:
   107     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   104     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   108     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
   105     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
   109     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
   106     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
   110   tasks:
   107   tasks:
   119 
   116 
   120 #
   117 #
   121 # Localhost actions
   118 # Localhost actions
   122 #
   119 #
   123 - hosts: localhost
   120 - hosts: localhost
   124   vars_files:
   121   connection: local
   125     - "{{playbook_dir}}/deploy_vars.yml"
       
   126   vars:
   122   vars:
   127     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   123     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   128     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
   124     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
   129     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
   125     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
   130   tasks:
   126   tasks:
   163 #
   159 #
   164 # Static server
   160 # Static server
   165 #
   161 #
   166 - hosts: remote_static
   162 - hosts: remote_static
   167   become: yes
   163   become: yes
   168   vars_files:
       
   169     - "{{playbook_dir}}/deploy_vars.yml"
       
   170   vars:
   164   vars:
   171     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   165     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   172     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
   166     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
   173     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
   167     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
   174   tasks:
   168   tasks:
   211 #
   205 #
   212 # Annotations and discussion servers
   206 # Annotations and discussion servers
   213 #
   207 #
   214 - hosts: remote_annotations_api:remote_discussions
   208 - hosts: remote_annotations_api:remote_discussions
   215   become: yes
   209   become: yes
   216   vars_files:
       
   217     - "{{playbook_dir}}/deploy_vars.yml"
       
   218   vars:
   210   vars:
   219     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   211     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   220     clientjs_dir: "{{playbook_dir}}/../clientjs"
   212     clientjs_dir: "{{playbook_dir}}/../clientjs"
   221     annotation_api_dir: "{{playbook_dir}}/../server/sbin"
   213     annotation_api_dir: "{{playbook_dir}}/../server/sbin"
   222   tasks:
   214   tasks:
   244 #
   236 #
   245 # Annotations server
   237 # Annotations server
   246 #
   238 #
   247 - hosts: remote_annotations_api
   239 - hosts: remote_annotations_api
   248   become: yes
   240   become: yes
   249   vars_files:
       
   250     - "{{playbook_dir}}/deploy_vars.yml"
       
   251   vars:
   241   vars:
   252     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   242     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   253     clientjs_dir: "{{playbook_dir}}/../clientjs"
   243     clientjs_dir: "{{playbook_dir}}/../clientjs"
   254     annotation_api_dir: "{{playbook_dir}}/../server/sbin"
   244     annotation_api_dir: "{{playbook_dir}}/../server/sbin"
   255   tasks:
   245   tasks:
   330 #
   320 #
   331 - hosts: remote_discussions
   321 - hosts: remote_discussions
   332 
   322 
   333   become: yes
   323   become: yes
   334 
   324 
   335   vars_files:
       
   336     - "{{playbook_dir}}/deploy_vars.yml"
       
   337 
       
   338   vars:
   325   vars:
   339     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   326     isso_build_dir: "{{playbook_dir}}/build/tmp/isso"
   340     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
   327     dashboard_build_dir: "{{playbook_dir}}/build/tmp/dashboard"
   341     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
   328     clientjs_dir: "{{playbook_dir}}/build/tmp/dashboard/clientjs"
   342     dicussions_pkg_archive: "isso-{{discussions_pkg_version}}.tar.gz"
   329     dicussions_pkg_archive: "isso-{{discussions_pkg_version}}.tar.gz"