Zack Williams | fc102dd | 2016-03-01 17:31:30 -0700 | [diff] [blame] | 1 | --- |
| 2 | # roles/cloudlab-prep/tasks/main.yml |
| 3 | |
Zack Williams | ef434f8 | 2016-04-07 17:15:39 -0700 | [diff] [blame] | 4 | - name: create directories to mount extra filesystems |
Zack Williams | 5ae57ef | 2016-04-12 14:01:58 -0700 | [diff] [blame] | 5 | file: |
Andy Bavier | 3a1d064 | 2016-07-01 14:11:39 -0400 | [diff] [blame] | 6 | dest={{ item.mount }} |
Zack Williams | ef434f8 | 2016-04-07 17:15:39 -0700 | [diff] [blame] | 7 | state=directory |
| 8 | with_items: "{{ cloudlab_extrafs }}" |
| 9 | |
| 10 | |
Zack Williams | 2fa7ca4 | 2016-04-11 12:45:10 -0700 | [diff] [blame] | 11 | # FIXME: does not create lost+found, -q makes it fail without error... |
Zack Williams | ef434f8 | 2016-04-07 17:15:39 -0700 | [diff] [blame] | 12 | - name: Set up extra disk space |
Andy Bavier | 3a1d064 | 2016-07-01 14:11:39 -0400 | [diff] [blame] | 13 | command: /usr/testbed/bin/mkextrafs -r {{ item.dev }} -qf {{ item.mount }} |
| 14 | creates={{ item.mount }}/lost+found |
Zack Williams | ef434f8 | 2016-04-07 17:15:39 -0700 | [diff] [blame] | 15 | with_items: "{{ cloudlab_extrafs }}" |
Andy Bavier | 66ee901 | 2016-07-20 17:25:51 -0400 | [diff] [blame] | 16 | register: result |
| 17 | until: result | success |
| 18 | retries: 3 |
| 19 | delay: 5 |
Zack Williams | fc102dd | 2016-03-01 17:31:30 -0700 | [diff] [blame] | 20 | |
Andy Bavier | 69e2061 | 2016-11-14 05:52:31 -0800 | [diff] [blame] | 21 | - name: Set up symlink targets |
| 22 | file: |
| 23 | path: "{{ item.src }}" |
| 24 | state: directory |
| 25 | with_items: "{{ cloudlab_links }}" |
| 26 | |
| 27 | - name: Create symlinks |
| 28 | file: |
| 29 | src: "{{ item.src }}" |
| 30 | dest: "{{ item.dest }}" |
| 31 | state: link |
| 32 | with_items: "{{ cloudlab_links }}" |