Michal Zegan | 3a7e073 | 2018-12-19 11:51:26 +0100 | [diff] [blame] | 1 | --- |
| 2 | - name: Change ownership of nexus_data |
| 3 | file: |
| 4 | path: "{{ app_data_path }}/nexus_data" |
| 5 | owner: 200 |
| 6 | group: 200 |
| 7 | recurse: yes |
| 8 | |
| 9 | - name: Load nexus image |
| 10 | docker_image: |
| 11 | name: sonatype/nexus3 |
| 12 | load_path: "{{ app_data_path }}/offline_data/docker_images_infra/sonatype_nexus3_latest.tar" |
| 13 | state: present |
| 14 | |
| 15 | - name: Create nexus network |
| 16 | docker_network: |
| 17 | name: nexus_network |
| 18 | state: present |
| 19 | |
| 20 | - name: Run nexus container |
| 21 | docker_container: |
| 22 | name: nexus |
| 23 | image: sonatype/nexus3 |
| 24 | networks: |
| 25 | - name: nexus_network |
| 26 | volumes: |
| 27 | - "{{ app_data_path }}/nexus_data:/nexus-data:rw" |
| 28 | state: started |
| 29 | restart_policy: unless-stopped |