浏览代码

Fix Docker build when sourced from artifacts

This commit fixes an issue when the artifact used to build the Docker
image is sourced from artifacts.elastic.co. In particular, the artifact
was not downloaded to the proper location.
Jason Tedor 6 年之前
父节点
当前提交
fe5a1490be
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      distribution/docker/build.gradle

+ 1 - 1
distribution/docker/build.gradle

@@ -23,7 +23,7 @@ ext.expansions = { oss ->
   return [
     'elasticsearch'       : elasticsearch,
     'license'             : oss ? 'Apache-2.0' : 'Elastic License',
-    'source_elasticsearch': local() ? "COPY $elasticsearch /opt/" : "RUN curl --retry 8 -s -L -O https://artifacts.elastic.co/downloads/elasticsearch/${elasticsearch}",
+    'source_elasticsearch': local() ? "COPY $elasticsearch /opt/" : "RUN cd /opt && curl --retry 8 -s -L -O https://artifacts.elastic.co/downloads/elasticsearch/${elasticsearch} && cd -",
     'version'             : VersionProperties.elasticsearch
   ]
 }