Add Docker build type (#39378)
This commit adds a new build type (together with deb/rpm/tar/zip) to represent the official Docker images. This build type will be displayed in APIs such as the main and nodes info APIs.
This commit is contained in:
parent
eb288a6f85
commit
504c792861
|
@ -31,6 +31,8 @@ WORKDIR /usr/share/elasticsearch
|
|||
COPY ${elasticsearch} /opt/
|
||||
|
||||
RUN tar zxf /opt/${elasticsearch} --strip-components=1
|
||||
RUN grep ES_DISTRIBUTION_TYPE=tar /usr/share/elasticsearch/bin/elasticsearch-env \
|
||||
&& sed -ie 's/ES_DISTRIBUTION_TYPE=tar/ES_DISTRIBUTION_TYPE=docker/' /usr/share/elasticsearch/bin/elasticsearch-env
|
||||
RUN mkdir -p config data logs
|
||||
RUN chmod 0775 config data logs
|
||||
COPY config/elasticsearch.yml config/log4j2.properties config/
|
||||
|
|
|
@ -75,6 +75,7 @@ public class Build {
|
|||
public enum Type {
|
||||
|
||||
DEB("deb"),
|
||||
DOCKER("docker"),
|
||||
RPM("rpm"),
|
||||
TAR("tar"),
|
||||
ZIP("zip"),
|
||||
|
@ -94,6 +95,8 @@ public class Build {
|
|||
switch (displayName) {
|
||||
case "deb":
|
||||
return Type.DEB;
|
||||
case "docker":
|
||||
return Type.DOCKER;
|
||||
case "rpm":
|
||||
return Type.RPM;
|
||||
case "tar":
|
||||
|
|
Loading…
Reference in New Issue