服务弹性负载平衡在区域eu-central-1中不可用

时间:2016-03-20 13:35:12

标签: sockets amazon-web-services reverse-proxy amazon-elb aws-cli

我尝试使用aws cli在我的AWS Elastic loadbalancer上启用代理支持,并在尝试enable the proxy policy时出错。

Service elasticloadbalancing not available in region eu-central-1

我的实例是在法兰克福地区的eu-central-1b。我创建并将我的实例与i&m; m关联的负载均衡器也假设在eu-central-1b中。

我是如何在ELB上启用代理支持的?看起来无法通过AWS管理控制台完成,但必须从命令行完成。

1 个答案:

答案 0 :(得分:0)

@Michael - sqlbot - 确实是在我通过apt-get install awscli获得的awscli旧版本

使用pip安装最新版本,如下所示,升级到import scrapy class eroskiSpider(scrapy.Spider): name = "eroski" allowed_domains = ['https://www.compraonline.com'] start_urls = [ 'https://www.compraonline.grupoeroski.com/es/' ] counter = 0 def parse(self, response): for sel in response.xpath('//nav[@class="navmenu"]/ul/li/div/ul/li'): cat_title = sel.xpath('a/@title')[0].extract() href = sel.xpath('a/@href')[0].extract() url = response.urljoin(href) print 'Parsing category ' + cat_title yield scrapy.Request(url, callback = self.parse_cat, dont_filter = True) break def parse_cat(self, response): category = response.xpath('//head/title/text()').extract_first() counter = 0 for sel in response.xpath('//article'): counter = counter + 1 print 'counter is ' + str(counter) description = sel.xpath('.//h2[contains(@class, "description_title")]/a/@title').extract_first() print description payload = {'pageNumber': '2', 't:zoneid': 'zoneScroll'} yield scrapy.FormRequest(url = response.url, formdata = payload, dont_filter=True)

<强> aws-cli/1.10.14 Python/2.7.6 Linux/3.13.0-74-generic botocore/1.4.5

在〜/ .aws / credentials上设置凭据并发出相同的命令,它运行正常。