version = self.api.manager.GetVersion(self.api, {})
pprinter.pprint(version)
+
@add_options('-x', '--xrn', dest='xrn', metavar='<xrn>', help='authority to list (hrn/urn - mandatory)')
@add_options('-t', '--type', dest='type', metavar='<type>', help='object type', default='all')
@add_options('-r', '--recursive', dest='recursive', metavar='<recursive>', help='list all child records',
options.verbose = verbose
terminal_render(list, options)
+
@add_options('-x', '--xrn', dest='xrn', metavar='<xrn>', help='object hrn/urn (mandatory)')
@add_options('-t', '--type', dest='type', metavar='<type>', help='object type', default=None)
@add_options('-o', '--outfile', dest='outfile', metavar='<outfile>', help='save record to file')
record_dict.update(extras)
return record_dict
+
@add_options('-x', '--xrn', dest='xrn', metavar='<xrn>', help='object hrn/urn', default=None)
@add_options('-t', '--type', dest='type', metavar='<type>', help='object type (mandatory)')
@add_options('-a', '--all', dest='all', metavar='<all>', action='store_true', default=False, help='check all users GID')
Users having a GID/PubKey correpondence OK: %s and are: \n%s\n\n\
Users having a GID/PubKey correpondence NOT OK: %s and are: \n%s\n\n" % (len(NOKEY), NOKEY, len(ERROR), ERROR, len(OK), OK, len(NOK), NOK))
+
@add_options('-x', '--xrn', dest='xrn', metavar='<xrn>', help='object hrn/urn (mandatory)')
@add_options('-t', '--type', dest='type', metavar='<type>', help='object type', default=None)
@add_options('-e', '--email', dest='email', default="",
url=url, description=description, extras=extras)
self.api.manager.Register(self.api, record_dict)
+
@add_options('-x', '--xrn', dest='xrn', metavar='<xrn>', help='object hrn/urn (mandatory)')
@add_options('-t', '--type', dest='type', metavar='<type>', help='object type', default=None)
@add_options('-u', '--url', dest='url', metavar='<url>', help='URL', default=None)
url=url, description=description, extras=extras)
self.api.manager.Update(self.api, record_dict)
+
@add_options('-x', '--xrn', dest='xrn', metavar='<xrn>', help='object hrn/urn (mandatory)')
@add_options('-t', '--type', dest='type', metavar='<type>', help='object type', default=None)
def remove(self, xrn, type=None):
xrn = Xrn(xrn, type)
self.api.manager.Remove(self.api, xrn)
+
@add_options('-x', '--xrn', dest='xrn', metavar='<xrn>', help='object hrn/urn (mandatory)')
@add_options('-t', '--type', dest='type', metavar='<type>', help='object type', default=None)
def credential(self, xrn, type=None):
self.api, xrn, type, self.api.hrn)
print(cred)
+
def import_registry(self):
"""Run the importer"""
from sfa.importer import Importer
importer = Importer()
importer.run()
+
def sync_db(self):
"""Initialize or upgrade the db"""
from sfa.storage.dbschema import DBSchema
dbschema = DBSchema()
dbschema.init_or_upgrade()
+
@add_options('-a', '--all', dest='all', metavar='<all>', action='store_true', default=False,
help='Remove all registry records and all files in %s area' % help_basedir)
@add_options('-c', '--certs', dest='certs', metavar='<certs>', action='store_true', default=False,