Beispiel #1
0
    def start(self):
        """Retrieve a long list of all files in a container."""

        # Package up the Payload
        payload = http.prep_payload(auth=self.auth,
                                    container=None,
                                    source=None,
                                    args=ARGS)

        # Prep Actions.
        self.go = actions.CloudActions(payload=payload)

        report.reporter(msg='PAYLOAD\t: "%s"' % payload,
                        log=True,
                        lvl='debug',
                        prt=False)

        with multi.spinner():
            if ARGS.get('cdn_info'):
                url = payload['cnet']
            else:
                url = payload['url']
            message = self.go.detail_show(url=url)

        try:
            if message.status_code != 404:
                report.reporter(msg='Object Found...')
                report.reporter(
                    msg=report.print_virt_table(dict(message.headers)))
            else:
                report.reporter(msg='Nothing Found...')
        except ValueError as exp:
            report.reporter(msg=('Non-hashable Type, Likley Item is not found.'
                                 ' Additional Data: %s' % exp))
Beispiel #2
0
    def start(self):
        """Retrieve a long list of all files in a container."""

        # Package up the Payload
        payload = http.prep_payload(
            auth=self.auth,
            container=None,
            source=None,
            args=ARGS
        )

        # Prep Actions.
        self.go = actions.CloudActions(payload=payload)

        report.reporter(
            msg='PAYLOAD\t: "%s"' % payload,
            log=True,
            lvl='debug',
            prt=False
        )

        with multi.spinner():
            if ARGS.get('cdn_info'):
                url = payload['cnet']
            else:
                url = payload['url']

            message = self.go.detail_show(url=url)

        if isinstance(message, list):
            report.reporter(msg='Item Found...')
            report.reporter(msg=report.print_virt_table(dict(message)))
        else:
            report.reporter(msg=message)
Beispiel #3
0
    def start(self):
        """Retrieve a long list of all files in a container."""

        # Package up the Payload
        payload = http.prep_payload(auth=self.auth,
                                    container=None,
                                    source=None,
                                    args=ARGS)

        # Prep Actions.
        self.go = actions.CloudActions(payload=payload)

        report.reporter(msg='PAYLOAD\t: "%s"' % payload,
                        log=True,
                        lvl='debug',
                        prt=False)

        with multi.spinner():
            if ARGS.get('cdn_info'):
                url = payload['cnet']
            else:
                url = payload['url']

            message = self.go.detail_show(url=url)

        if isinstance(message, list):
            report.reporter(msg='Item Found...')
            report.reporter(msg=report.print_virt_table(dict(message)))
        else:
            report.reporter(msg=message)
Beispiel #4
0
    def start(self):
        """Retrieve a long list of all files in a container."""

        # Package up the Payload
        payload = http.prep_payload(auth=self.auth, container=None, source=None, args=ARGS)

        # Prep Actions.
        self.go = actions.CloudActions(payload=payload)

        report.reporter(msg='PAYLOAD\t: "%s"' % payload, log=True, lvl="debug", prt=False)

        with multi.spinner():
            if ARGS.get("cdn_info"):
                url = payload["cnet"]
            else:
                url = payload["url"]
            message = self.go.detail_show(url=url)

        try:
            if message.status_code != 404:
                report.reporter(msg="Object Found...")
                report.reporter(msg=report.print_virt_table(dict(message.headers)))
            else:
                report.reporter(msg="Nothing Found...")
        except ValueError as exp:
            report.reporter(msg=("Non-hashable Type, Likley Item is not found." " Additional Data: %s" % exp))
Beispiel #5
0
    def start(self):
        """Retrieve a long list of all files in a container."""

        # Package up the Payload
        payload = http.prep_payload(
            auth=self.auth,
            container=None,
            source=None,
            args=ARGS
        )

        # Prep Actions.
        self.go = actions.CloudActions(payload=payload)

        report.reporter(
            msg='PAYLOAD : [ %s ]' % payload,
            prt=False,
            lvl='debug',
        )

        with multi.spinner():
            if ARGS.get('cdn_info'):
                url = payload['cnet']
            else:
                url = payload['url']
            message = self.go.detail_show(url=url)

        try:
            if message.status_code != 404:
                report.reporter(msg='Object Found...')
                report.reporter(
                    msg=report.print_virt_table(dict(message.headers)),
                    log=False
                )
            else:
                report.reporter(msg='Nothing Found...')
        except ValueError as exp:
            report.reporter(
                msg=('Non-hashable Type, Likley Item is not found.'
                     ' Additional Data: %s' % exp)
            )