]> git.apps.os.sepia.ceph.com Git - ceph-cm-ansible.git/commitdiff
puddle: add ceph-puddle wrapper script 20/head
authorKen Dreyer <kdreyer@redhat.com>
Tue, 5 May 2015 22:12:05 +0000 (16:12 -0600)
committerKen Dreyer <kdreyer@redhat.com>
Tue, 5 May 2015 22:14:28 +0000 (16:14 -0600)
This wraps k5start and Puddle so I don't have to remember the exact
command and keytab location. I can now simply run "ceph-puddle", like
so:

  $ ceph-puddle /etc/puddle/ceph/ceph-1.3-rhel-7.conf

The purpose of this commit is to make it easier/simpler to run Puddle
with Kerberos credentials.

roles/puddle/tasks/configure.yml
roles/puddle/templates/ceph-puddle [new file with mode: 0755]

index 32869d4428cb496baebfc1a3a179b4aab8558303..d073fe18daada01dd5eaf5de9a86369ef721aae0 100644 (file)
     mode: 0644
   notify:
    - restart faucet
+
+- name: add ceph wrapper script for puddle
+  template:
+    src: 'ceph-puddle'
+    dest: '/usr/local/bin/ceph-puddle'
+    owner: root
+    group: root
+    mode: 0755
diff --git a/roles/puddle/templates/ceph-puddle b/roles/puddle/templates/ceph-puddle
new file mode 100755 (executable)
index 0000000..b23fa04
--- /dev/null
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+#
+# {{ ansible_managed }}
+#
+
+# In order to allow Puddle to communicate with Red Hat's Errata Tool, we need
+# active Kerberos credentials. This script wraps /usr/bin/puddle with the
+# k5start utility.
+
+set -e
+
+exec k5start -U -f {{ puddle.kerberos_keytab }} -- puddle "$@"