Skip to content

Commit f7aa97c

Browse files
committed
[CI] Refactors Dockerfile to allow RUBY_SOURCE for docker image
1 parent d8cb3fa commit f7aa97c

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

.buildkite/Dockerfile

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
ARG RUBY_VERSION=${RUBY_VERSION:-3.1}
2-
FROM ruby:$RUBY_VERSION
2+
ARG RUBY_SOURCE=${RUBY_SOURCE:-ruby}
3+
FROM $RUBY_SOURCE:$RUBY_VERSION
34

45
# Default UID/GID to 1000
56
# it can be overridden at build time

.buildkite/pipeline.yml

+7-1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ steps:
77
TEST_SUITE: "{{ matrix.suite }}"
88
STACK_VERSION: 8.10.0-SNAPSHOT
99
TRANSPORT_VERSION: "{{ matrix.transport }}"
10+
RUBY_SOURCE: "{{ matrix.ruby_source }}"
1011
matrix:
1112
setup:
1213
suite:
@@ -16,9 +17,10 @@ steps:
1617
- "3.2"
1718
- "3.1"
1819
- "3.0"
19-
- "jruby-9.3"
2020
transport:
2121
- "8.2"
22+
ruby_source:
23+
- 'ruby'
2224
# Only run platinum once for the latest Ruby. You can use lots of combinations, check the
2325
# documentation on https://buildkite.com/docs/pipelines/build-matrix for more information.
2426
adjustments:
@@ -42,6 +44,10 @@ steps:
4244
suite: "free"
4345
ruby: "3.2"
4446
transport: "main"
47+
- with:
48+
suite: 'free'
49+
ruby: '9.3'
50+
ruby_source: 'jruby'
4551
command: ./.buildkite/run-tests.sh
4652
# I'm publishing test results to HTML and JUnit in this directory and this directive makes them
4753
# available in the Artifacts tab of a build in Buildkite.

.buildkite/run-client.sh

+1
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ docker build \
1515
--tag elastic/elasticsearch-ruby \
1616
--build-arg RUBY_VERSION=$RUBY_VERSION \
1717
--build-arg TRANSPORT_VERSION=$TRANSPORT_VERSION \
18+
--build-arg RUBY_SOURCE=$RUBY_SOURCE \
1819
.
1920

2021
mkdir -p elasticsearch-api/tmp

0 commit comments

Comments
 (0)