Skip to content

Commit 333c04f

Browse files
authored
Merge pull request #94 from piersharding/master
Enable override of base command used in the command role
2 parents 4414131 + f622c98 commit 333c04f

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

roles/commands/README.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,14 @@ with at least one host in it - see the `cephadm` role for more details.
1919

2020
## Role variables
2121

22-
* `cephadm_commands`: A list of commands to pass to `cephadm shell -- ceph`
22+
23+
* `cephadm_command`: The command to use with the list of commands to execute - defaults to `ceph`, but can be any command found in the `quay.io/ceph/ceph:<tag>` image.
24+
Example:
25+
```
26+
cephadm_command: radosgw-admin
27+
```
28+
29+
* `cephadm_commands`: A list of commands to pass to `cephadm shell -- {{ cephadm_command }}`
2330
Example:
2431
```
2532
cephadm_commands:

roles/commands/defaults/main.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
---
2+
cephadm_command: ceph
23
cephadm_commands: []

roles/commands/tasks/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
- name: Execute custom commands
33
command:
4-
cmd: "cephadm shell -- ceph {{ item }}"
4+
cmd: "cephadm shell -- {{ cephadm_command }} {{ item }}"
55
register: cephadm_commands_result
66
with_items: "{{ cephadm_commands }}"
77
become: true

0 commit comments

Comments
 (0)