title: Dockerfile: not able to run bin command ubuntu
body: <p>Trying to get elasticsearch installed and running into an error here in my dockerfile. Looks like it's unable to run bin.</p>
  
  <pre><code>#JDK 1.8 on Ubuntu for ElasticSearch
  RUN add-apt-repository -y ppa:webupd8team/java
  RUN apt-get -y update
  RUN apt-get -y install openjdk-8-jre
  RUN wget -qO – https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add –
  RUN apt-get install apt-transport-https
  RUN echo “deb https://artifacts.elastic.co/packages/6.x/apt stable main” | tee -a /etc/apt/sources.list.d/elastic-6.x.list
  RUN apt-get update
  RUN apt-get install elasticsearch
  RUN /usr/share/elasticsearch/bin/elasticsearch-plugin install analysis-icu
  RUN /usr/share/elasticsearch/bin/elasticsearch-plugin install analysis-phonetic
  RUN -service elasticsearch start
  RUN gedit /etc/elasticsearch/jvm.options
  RUN gedit /etc/elasticsearch/elasticsearch.yml
  RUN curl -XGET ‘http://localhost:9200/_cat/health?v&amp;pretty’
  </code></pre>
  
  <hr>
  
  <pre><code>Step 21/70 : RUN wget -qO – https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add –
   ---&gt; Running in 7558b8a264b8
  Warning: apt-key output should not be parsed (stdout is not a terminal)
  gpg: no valid OpenPGP data found.
  The command '/bin/sh -c wget -qO – https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add –' returned a non-zero code: 2
  </code></pre>
  
  <p>Kind of new to docker so any help would be greatly appreciated. I'm running root user so i don't need to add sudo in front of any of these commands.</p>