-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sit.cephfs: Make ceph repo creation a common task
Performing the task of ceph repo creation from common.prep role makes it possible to include it as part of preparing client machines. Signed-off-by: Anoop C S <[email protected]>
- Loading branch information
Showing
3 changed files
with
32 additions
and
27 deletions.
There are no files selected for viewing
21 changes: 21 additions & 0 deletions
21
playbooks/ansible/roles/sit.cephfs/tasks/common/centos.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
- name: Identify latest ceph:{{ config.data.branch }} build | ||
uri: | ||
url: "https://shaman.ceph.com/api/search?\ | ||
project=ceph&\ | ||
ref={{ config.data.branch }}&\ | ||
flavor=default&\ | ||
status=ready&\ | ||
distros=centos/{{ config.os[site.os].version }}/x86_64&\ | ||
sha1=latest" | ||
return_content: true | ||
register: ceph_shaman | ||
|
||
- name: Create ceph repo | ||
yum_repository: | ||
name: "ceph-{{ config.data.branch }}-{{ ceph_shaman.json[0].sha1 }}" | ||
baseurl: "{{ ceph_shaman.json[0].url }}/x86_64" | ||
description: "Ceph {{ config.data.branch }} ({{ ceph_shaman.json[0].sha1 }})" | ||
enabled: true | ||
gpgcheck: false | ||
state: present |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,9 @@ | ||
--- | ||
- name: Process OS specific tasks | ||
include_tasks: "{{ include_file }}" | ||
vars: | ||
prefix: "{{ role_path }}/tasks/common/" | ||
with_first_found: | ||
- files: "{{ [prefix] | product(config.os[site.os].includes) | map('join') | list }}" | ||
loop_control: | ||
loop_var: include_file |
30 changes: 3 additions & 27 deletions
30
playbooks/ansible/roles/sit.cephfs/tasks/server/centos.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters