]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-daemon: add --skip-pull 31478/head
authorSage Weil <sage@redhat.com>
Fri, 8 Nov 2019 13:10:53 +0000 (07:10 -0600)
committerSage Weil <sage@redhat.com>
Fri, 8 Nov 2019 13:10:53 +0000 (07:10 -0600)
It occurs to me there might be cases where the user *doesn't* want to pull
the latest image (e.g., because it is a partially disconnected enviroment,
and they know the image is already in the local registry).

Signed-off-by: Sage Weil <sage@redhat.com>
src/ceph-daemon

index 15033700482a60588fa0df92afc30e63d65660e5..a7bf2e2fde6758d936483566c4745e2ee77e2878 100755 (executable)
@@ -842,8 +842,9 @@ def command_bootstrap():
         if ret:
             raise RuntimeError('Failed to ping %s' % mon_ip)
 
-    logger.info('Pulling latest %s container...' % args.image)
-    call_throws([podman_path, 'pull', args.image])
+    if not args.skip_pull:
+        logger.info('Pulling latest %s container...' % args.image)
+        call_throws([podman_path, 'pull', args.image])
 
     logger.info('Extracting ceph user uid/gid from container image...')
     (uid, gid) = extract_uid_gid()
@@ -1719,6 +1720,10 @@ def _get_parser():
         '--skip-ping-check',
         action='store_true',
         help='do not verify that mon IP is pingable')
+    parser_bootstrap.add_argument(
+        '--skip-pull',
+        action='store_true',
+        help='do not pull the latest image before bootstrapping')
 
     parser_deploy = subparsers.add_parser(
     'deploy', help='deploy a daemon')