Example #1
0
    def render(self, session, logger, share,
               comments, hostname, resourcegroup, cluster, **arguments):

        validate_basic("share", share)
        holder = get_resource_holder(session,
                                     hostname, cluster, resourcegroup,
                                     compel=False)

        Share.get_unique(session, name=share, holder=holder, preclude=True)

        dbshare = Share(name=share, comments=comments)
        add_resource(session, logger, holder, dbshare)

        return
Example #2
0
    def render(self, session, logger, share, comments, hostname, resourcegroup,
               cluster, **arguments):

        validate_basic("share", share)
        holder = get_resource_holder(session,
                                     hostname,
                                     cluster,
                                     resourcegroup,
                                     compel=False)

        Share.get_unique(session, name=share, holder=holder, preclude=True)

        dbshare = Share(name=share, comments=comments)
        add_resource(session, logger, holder, dbshare)

        return
Example #3
0
 def render(self, session, logger, share, hostname, resourcegroup, cluster,
            **arguments):
     holder = get_resource_holder(session, hostname, cluster, resourcegroup)
     dbshare = Share.get_unique(session, name=share, holder=holder,
                                compel=True)
     del_resource(session, logger, dbshare)
     return
Example #4
0
    def render(self, session, logger, share, hostname, resourcegroup, cluster,
               **arguments):

        validate_basic("share", share)
        holder = get_resource_holder(session, hostname, cluster, resourcegroup)
        dbshare = Share.get_unique(session,
                                   name=share,
                                   holder=holder,
                                   compel=True)
        del_resource(session, logger, dbshare)
        return