File tree 8 files changed +96
-1
lines changed
Test/Functional/Acceptance
8 files changed +96
-1
lines changed Original file line number Diff line number Diff line change
1
+ FROM opensearchproject/opensearch:1.3.0
2
+
3
+ USER root
4
+ RUN yum -y install zip && \
5
+ zip -q -d /usr/share/opensearch/lib/log4j-core-*.jar org/apache/logging/log4j/core/lookup/JndiLookup.class && \
6
+ yum remove -y zip && \
7
+ yum -y clean all && \
8
+ rm -rf /var/cache
9
+ USER opensearch
10
+
11
+ RUN bin/opensearch-plugin install -b analysis-icu && \
12
+ bin/opensearch-plugin install -b analysis-phonetic
13
+
14
+ ADD docker-healthcheck.sh /docker-healthcheck.sh
15
+ ADD docker-entrypoint.sh /docker-entrypoint.sh
16
+
17
+ HEALTHCHECK --retries=3 CMD ["bash" , "/docker-healthcheck.sh" ]
18
+
19
+ ENTRYPOINT ["/docker-entrypoint.sh" ]
20
+
21
+ EXPOSE 9200 9300
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+ set -eo pipefail
3
+
4
+ if [[ -n " $OS_PLUGINS " ]]; then
5
+ echo " Installing plugins: $OS_PLUGINS "
6
+ for PLUGIN in $OS_PLUGINS
7
+ do
8
+ ./bin/opensearch-plugin install -b " $PLUGIN "
9
+ done
10
+ fi
11
+
12
+ /bin/bash /usr/share/opensearch/opensearch-docker-entrypoint.sh
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+ set -eo pipefail
3
+
4
+ if health=" $( curl -fsSL " http://${OS_HOST:- opensearch} :${OS_HOST:- 9200} /_cat/health?h=status" ) " ; then
5
+ health=" $( echo " $health " | sed -r ' s/^[[:space:]]+|[[:space:]]+$//g' ) " # trim whitespace (otherwise we'll have "green ")
6
+ if [ " $health " = ' green' ] || [ " $health " = ' yellow' ]; then
7
+ exit 0
8
+ fi
9
+ echo >&2 " Unexpected health status: $health "
10
+ fi
11
+
12
+ exit 1
Original file line number Diff line number Diff line change
1
+ FROM opensearchproject/opensearch:2.12.0
2
+
3
+ USER root
4
+ RUN yum -y install zip && \
5
+ zip -q -d /usr/share/opensearch/lib/log4j-core-*.jar org/apache/logging/log4j/core/lookup/JndiLookup.class && \
6
+ yum remove -y zip && \
7
+ yum -y clean all && \
8
+ rm -rf /var/cache
9
+ USER opensearch
10
+
11
+ RUN bin/opensearch-plugin install -b analysis-icu && \
12
+ bin/opensearch-plugin install -b analysis-phonetic
13
+
14
+ ADD docker-healthcheck.sh /docker-healthcheck.sh
15
+ ADD docker-entrypoint.sh /docker-entrypoint.sh
16
+
17
+ HEALTHCHECK --retries=3 CMD ["bash" , "/docker-healthcheck.sh" ]
18
+
19
+ ENTRYPOINT ["/docker-entrypoint.sh" ]
20
+
21
+ EXPOSE 9200 9300
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+ set -eo pipefail
3
+
4
+ if [[ -n " $OS_PLUGINS " ]]; then
5
+ echo " Installing plugins: $OS_PLUGINS "
6
+ for PLUGIN in $OS_PLUGINS
7
+ do
8
+ ./bin/opensearch-plugin install -b " $PLUGIN "
9
+ done
10
+ fi
11
+
12
+ /bin/bash /usr/share/opensearch/opensearch-docker-entrypoint.sh
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+ set -eo pipefail
3
+
4
+ if health=" $( curl -fsSL " http://${OS_HOST:- opensearch} :${OS_HOST:- 9200} /_cat/health?h=status" ) " ; then
5
+ health=" $( echo " $health " | sed -r ' s/^[[:space:]]+|[[:space:]]+$//g' ) " # trim whitespace (otherwise we'll have "green ")
6
+ if [ " $health " = ' green' ] || [ " $health " = ' yellow' ]; then
7
+ exit 0
8
+ fi
9
+ echo >&2 " Unexpected health status: $health "
10
+ fi
11
+
12
+ exit 1
Original file line number Diff line number Diff line change @@ -34,6 +34,9 @@ class GenerateOs extends Command
34
34
'1.2 ' => [
35
35
'real-version ' => '1.2.1 ' ,
36
36
],
37
+ '1.3 ' => [
38
+ 'real-version ' => '1.3.0 ' ,
39
+ ],
37
40
'2.3 ' => [
38
41
'real-version ' => '2.3.0 '
39
42
],
@@ -42,6 +45,9 @@ class GenerateOs extends Command
42
45
],
43
46
'2.5 ' => [
44
47
'real-version ' => '2.5.0 '
48
+ ],
49
+ '2.12 ' => [
50
+ 'real-version ' => '2.12.0 '
45
51
]
46
52
];
47
53
Original file line number Diff line number Diff line change @@ -20,5 +20,4 @@ class Opensearch82Cest extends OpensearchCest
20
20
* Template version for testing
21
21
*/
22
22
protected const TEMPLATE_VERSION = '2.4.6 ' ;
23
-
24
23
}
You can’t perform that action at this time.
0 commit comments