]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-deploy.git/commitdiff
call ceph-mon in hosts.common
authorAlfredo Deza <alfredo.deza@inktank.com>
Thu, 20 Feb 2014 20:49:15 +0000 (15:49 -0500)
committerAlfredo Deza <alfredo.deza@inktank.com>
Fri, 21 Feb 2014 14:46:44 +0000 (09:46 -0500)
Signed-off-by: Alfredo Deza <alfredo.deza@inktank.com>
ceph_deploy/hosts/common.py

index 0238f400cd60a64c4846b343cf48c740c4ab3a4f..c8ffb0983845b07aee30e61072bc5fc4aabb9b15 100644 (file)
@@ -67,7 +67,8 @@ def mon_create(distro, args, monitor_keyring, hostname):
     distro.conn.remote_module.create_init_path(init_path)
 
 
-def mon_add(distro, args, monitor_keyring, hostname):
+def mon_add(distro, args, monitor_keyring):
+    hostname = distro.conn.remote_module.shortname()
     logger = distro.conn.logger
     path = paths.mon.path(args.cluster, hostname)
     monmap_path = paths.mon.monmap(args.cluster, hostname)
@@ -149,3 +150,14 @@ def mon_add(distro, args, monitor_keyring, hostname):
     # create init path
     distro.conn.remote_module.create_init_path(init_path)
 
+    # start the mon using the address
+    process.run(
+        distro.conn,
+        [
+            'ceph-mon',
+            '-i',
+            hostname,
+            '--public-addr',
+            args.address,
+        ],
+    )