# Using amazon\_es output plugin via proxy

**URL:** <https://discuss.elastic.co/t/using-amazon-es-output-plugin-via-proxy/62192>\
**Category:** Logstash\
**Created:** [October 4, 2016, 5:03pm UTC](https://discuss.elastic.co/t/using-amazon-es-output-plugin-via-proxy/62192 "2016-10-04T17:03:51Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![kvinell](https://avatars.discourse-cdn.com/v4/letter/k/46a35a/32.png) [@kvinell](https://discuss.elastic.co/u/kvinell)\
**Post date:** [October 4, 2016, 5:03pm UTC](https://discuss.elastic.co/t/using-amazon-es-output-plugin-via-proxy/62192/1 "2016-10-04T17:03:51Z")

</div>

Hi,

I'm trying to use amazon\_es output plugin for Logstash to send data to my Elasticsearch cluster in AWS (Elasticsearch service). However, the Logstash instance is installed on a server that needs to go through a proxy to access the internet, and as far as I can tell from the amazon\_es documentation ([https://github.com/awslabs/logstash-output-amazon\_es](https://github.com/awslabs/logstash-output-amazon_es)) there is no way of specifying a proxy for the outbound traffic.

When trying to send data with the amazon\_es plugin, I now get the following error in the logstash.log file:

```
{:timestamp=>"2016-10-04T18:40:13.697000+0200", :message=>"Attempted to send a bulk request to Elasticsearch configured at '[\"https://subdomain.mydomain.com:443\"]', but an error occurred and it failed! Are you sure you can reach elasticsearch from this machine using the configuration provided?", :client_config=>{:hosts=>["https://subdomain.mydomain.com:443"], :region=>"eu-west-1", :aws_access_key_id=>nil, :aws_secret_access_key=>nil, :transport_options=>{:request=>{:open_timeout=>0, :timeout=>60}, :proxy=>nil}, :transport_class=>Elasticsearch::Transport::Transport:: ...

```

Judging by the error message, it seems that it would be possible to specify a proxy in the transport\_options but not exactly sure how.

My output plugin configuration looks like this:

```
output {
  amazon_es {
    hosts => ["subdomain.mydomain.com"]
    region => "eu-west-1"
    index => "acc-foobar-%{+YYYY.MM.dd}"
  }
}

```

(I'm not using my actual domain in the above examples...)

Also, I am reluctant to set HTTP\_PROXY or HTTPS\_PROXY due to security reasons.

Hope someone has an idea of how to approach this.

Many thanks,

Kristoffer Vinell

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [October 5, 2016, 9:51am UTC](https://discuss.elastic.co/t/using-amazon-es-output-plugin-via-proxy/62192/2 "2016-10-05T09:51:01Z")

</div>

I think you'll need to ask Amazon on their forums, this isn't a plugin we support.

---

<div class="post-metadata">

**Author:** ![GogLlundain](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/gogllundain/32/15620_2.png) [@GogLlundain](https://discuss.elastic.co/u/GogLlundain)\
**Post date:** [March 3, 2017, 2:06pm UTC](https://discuss.elastic.co/t/using-amazon-es-output-plugin-via-proxy/62192/3 "2017-03-03T14:06:23Z")

</div>

Hi kvinell,

Did you open an AWS ticket for this? Could you post a link?

However I've realised that the plugin does accept a proxy parameter. I've used this successfully with a http proxy but I did have issues trying to post through a secure proxy, I think the SSL certs weren't installed in the key store or something like that  
_shrug_

Gog

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 4:28am UTC](https://discuss.elastic.co/t/using-amazon-es-output-plugin-via-proxy/62192/4 "2017-07-06T04:28:07Z")

</div>


