title: Running Elasticsearch 8 on concourse container
body: <p>I'm using Concourse for building my java package.</p>
  <p>In order to run integration tests of that package, I need a local instance of elasticsearch present.</p>
  <p>Prior to ES version 8, all I was doing was installing ES in Docker image that I would then use as Concourse task's image resource to build my java package in:</p>
  <pre><code>FROM openjdk:11-jdk-slim-stretch
  RUN apt-get update &amp;&amp; apt-get install -y procps
  ADD &quot;https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.9.3-amd64.deb&quot; /es.deb
  RUN dpkg -i es.deb
  RUN rm es.deb
  </code></pre>
  <p>Later I would just start it right before building with:
  <code>/etc/init.d/elasticsearch start</code></p>
  <p>Problems started when upgrading ES to version 8. That <code>init.d</code> file does not seem to exist anymore. Some of the advices I found suggest running ES as a container, so running ES container inside of the concourse container which seems a bit too complex for my use case.</p>
  <p>If you had similar problems in your projects, how did you solve them?</p>