]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-deploy.git/commitdiff
install --gitbuilder-host alternative to gitbuilder.ceph.com
authorLoic Dachary <ldachary@redhat.com>
Thu, 24 Sep 2015 23:00:30 +0000 (01:00 +0200)
committerLoic Dachary <ldachary@redhat.com>
Fri, 25 Sep 2015 16:36:19 +0000 (18:36 +0200)
To be used with --gitbuilder-host gitbuilder.myself.net
--dev-commit 6f11b82f3007819b58f143ad4b4911c4fb766ab9. It is primarily
useful in the context of the ceph_deploy.py task, when a full gitbuilder
mirror is available, with the exact same directory layout.

Signed-off-by: Loic Dachary <loic@dachary.org>
ceph_deploy/hosts/centos/install.py
ceph_deploy/hosts/debian/install.py
ceph_deploy/hosts/fedora/install.py
ceph_deploy/install.py

index 503cc3d07aecfef541f369305b58efff7d13b427..fa20f39f8b867ecc224cf48986a5db57b676f5cf 100644 (file)
@@ -89,11 +89,13 @@ def install(distro, version_kind, version, adjust_repos, **kw):
             logger.info('repo file will be created manually')
             mirror_install(
                 distro,
-                'http://gitbuilder.ceph.com/ceph-rpm-centos{release}-{machine}-basic/{sub}/{version}/'.format(
+                'http://{gitbuilder_host}/ceph-rpm-centos{release}-{machine}-basic/{sub}/{version}/'.format(
                     release=release.split(".", 1)[0],
                     machine=machine,
                     sub='ref' if version_kind == 'dev' else 'sha1',
-                    version=version),
+                    version=version,
+                    gitbuilder_host=kw['gitbuilder_host'],
+                ),
                 gpg.url(key),
                 adjust_repos=True,
                 extra_installs=False
index 2fb88642296c2b881209703f364432c85ff0698d..6f30941a595e4b1fdaa07e4213873f597c744066 100644 (file)
@@ -36,11 +36,12 @@ def install(distro, version_kind, version, adjust_repos, **kw):
         elif version_kind == 'testing':
             url = 'http://download.ceph.com/debian-testing/'
         elif version_kind in ['dev', 'dev_commit']:
-            url = 'http://gitbuilder.ceph.com/ceph-deb-{codename}-{machine}-basic/{sub}/{version}'.format(
+            url = 'http://{gitbuilder_host}/ceph-deb-{codename}-{machine}-basic/{sub}/{version}'.format(
                 codename=codename,
                 machine=machine,
                 sub='ref' if version_kind == 'dev' else 'sha1',
                 version=version,
+                gitbuilder_host=kw['gitbuilder_host'],
                 )
         else:
             raise RuntimeError('Unknown version kind: %r' % version_kind)
index e71747512a090a7764d04f8d0ecb0de523dfa6e2..bf90c641fcf40291f371973a84e91c60b164dc46 100644 (file)
@@ -66,14 +66,15 @@ def install(distro, version_kind, version, adjust_repos, **kw):
             logger.info('repo file will be created manually')
             mirror_install(
                 distro,
-                'http://gitbuilder.ceph.com/ceph-rpm-fc{release}-{machine}-basic/{sub}/{version}/'.format(
+                'http://{gitbuilder_host}/ceph-rpm-fc{release}-{machine}-basic/{sub}/{version}/'.format(
                     release=release.split(".", 1)[0],
                     machine=machine,
                     sub='ref' if version_kind == 'dev' else 'sha1',
                     version=version),
                 gpg.url(key),
                 adjust_repos=True,
-                extra_installs=False
+                extra_installs=False,
+                gitbuilder_host=kw['gitbuilder_host'],
             )
 
         else:
index 7758af97e8105f4e28ba1202d528262b59d20175..614a204d3bd990d76ad506ff14246681161ba0b6 100644 (file)
@@ -183,6 +183,7 @@ def install(args):
                 version,
                 args.adjust_repos,
                 components=components,
+                gitbuilder_host=args.gitbuilder_host,
             )
 
         # Check the ceph version we just installed
@@ -591,6 +592,15 @@ def make(parser):
         help='specify a repo URL that mirrors/contains Ceph packages',
     )
 
+    parser.add_argument(
+        '--gitbuilder-host',
+        nargs='?',
+        dest='gitbuilder_host',
+        default='gitbuilder.ceph.com',
+        help='specify a gitbuilder host that mirrors/contains Ceph packages,\
+                to use with --dev or --dev-commit exclusively.',
+    )
+
     parser.add_argument(
         '--gpg-url',
         nargs='?',