def add_alias(self, alias):
        """Add an alias to the index set in the elastic obj

        :param alias: alias to add

        :returns: None
        """
        aliases = self.list_aliases()
        if alias in aliases:
            logger.debug("Alias %s already exists on %s.", alias, self.anonymize_url(self.index_url))
            return

        # add alias
        alias_data = """
        {
            "actions": [
                {
                    "add": {
                        "index": "%s",
                        "alias": "%s"
                    }
                }
            ]
        }
        """ % (self.index, alias)

        r = self.requests.post(self.url + "/_aliases", headers=HEADER_JSON, verify=False, data=alias_data)
        try:
            r.raise_for_status()
        except requests.exceptions.HTTPError as ex:
            logger.warning("Something went wrong when adding an alias on %s. Alias not set.",
                           self.anonymize_url(self.index_url))
            logger.warning(ex)
            return

        logger.info("Alias %s created on %s.", alias, self.anonymize_url(self.index_url))
Add an alias to the index set in the elastic obj

        :param alias: alias to add

        :returns: None