code: def _set_bucket_dns(self):
          
          # Different regions have different s3 endpoint formats
          dotformat_regions = ["eu-west-2", "eu-central-1", "ap-northeast-2", "ap-south-1", "ca-central-1", "us-east-2"]
          if self.region in dotformat_regions:
              s3_endpoint = "{0}.s3-website.{1}.amazonaws.com".format(self.bucket, self.region)
          else:
              s3_endpoint = "{0}.s3-website-{1}.amazonaws.com".format(self.bucket, self.region)
  
          zone_ids = get_dns_zone_ids(env=self.env, facing="public")
          dns_kwargs = {
              'dns_name': self.bucket,
              'dns_name_aws': s3_endpoint,
              'dns_ttl': self.properties['dns']['ttl']
          }
  
          for zone_id in zone_ids:
              LOG.debug('zone_id: %s', zone_id)
              update_dns_zone_record(self.env, zone_id, **dns_kwargs)
          LOG.info("Created DNS %s for Bucket", self.bucket)
docs: Create CNAME for S3 endpoint.