1313 matrix :
1414 # We need 1.10.6 here to check that module works with
1515 # old Tarantool versions that don't have "tuple-keydef"/"tuple-merger" support.
16+ # We test old metrics with Tarantool 2.10 because since Tarantool 2.11.1
17+ # it uses its own metrics package.
18+ # We test old metrics with Cartridge 2.7.9 because since 2.8.0 it
19+ # requires metrics 1.0.0.
1620 tarantool-version : ["1.10.6", "1.10", "2.2", "2.3", "2.4", "2.5", "2.6", "2.7", "2.8", "2.10", "2.11"]
1721 metrics-version : [""]
1822 cartridge-version : ["2.8.0"]
@@ -24,16 +28,19 @@ jobs:
2428 - tarantool-version : " 2.7"
2529 remove-merger : true
2630 cartridge-version : " 2.8.0"
27- - tarantool-version : " 2.11"
28- metrics-version : " 0.1.8"
29- cartridge-version : " 2.8.0"
30- - tarantool-version : " 2.11"
31+ - tarantool-version : " 2.10"
3132 metrics-version : " 0.10.0"
32- cartridge-version : " 2.8.0 "
33+ cartridge-version : " 2.7.9 "
3334 - tarantool-version : " 2.11"
3435 coveralls : true
3536 metrics-version : " 1.0.0"
3637 cartridge-version : " 2.8.0"
38+ - tarantool-version : " 2.11"
39+ metrics-version : " 1.0.0"
40+ vshard-version : " 0.1.24"
41+ - tarantool-version : " master"
42+ metrics-version : " 1.0.0"
43+ vshard-version : " 0.1.24"
3744 fail-fast : false
3845 # Can't install older versions on 22.04,
3946 # see https://github.com/tarantool/setup-tarantool/issues/36
@@ -42,10 +49,42 @@ jobs:
4249 - uses : actions/checkout@master
4350
4451 - name : Setup Tarantool CE
52+ if : matrix.tarantool-version != 'master'
4553 uses : tarantool/setup-tarantool@v2
4654 with :
4755 tarantool-version : ${{ matrix.tarantool-version }}
4856
57+ - name : Setup tt
58+ run : |
59+ curl -L https://tarantool.io/release/2/installer.sh | sudo bash
60+ sudo apt install -y tt
61+ tt version
62+
63+ - name : Get Tarantool master latest commit
64+ if : matrix.tarantool-version == 'master'
65+ run : |
66+ commit_hash=$(git ls-remote https://github.com/tarantool/tarantool.git --branch master | head -c 8)
67+ echo "LATEST_COMMIT=${commit_hash}" >> $GITHUB_ENV
68+ shell : bash
69+
70+ - name : Cache Tarantool master
71+ if : matrix.tarantool-version == 'master'
72+ id : cache-latest
73+ uses : actions/cache@v3
74+ with :
75+ path : " ${GITHUB_WORKSPACE}/bin"
76+ key : cache-latest-${{ env.LATEST_COMMIT }}
77+
78+ - name : Setup Tarantool master
79+ if : matrix.tarantool-version == 'master' && steps.cache-latest.outputs.cache-hit != 'true'
80+ run : |
81+ tt init
82+ tt install tarantool master
83+
84+ - name : Add Tarantool master to PATH
85+ if : matrix.tarantool-version == 'master'
86+ run : echo "${GITHUB_WORKSPACE}/bin" >> $GITHUB_PATH
87+
4988 - name : Fix luarocks in Tarantool CE 1.10.6
5089 if : matrix.tarantool-version == '1.10.6'
5190 run : |
@@ -57,10 +96,11 @@ jobs:
5796 ./deps.sh
5897 env :
5998 CARTRIDGE_VERSION : ${{ matrix.cartridge-version }}
99+ VSHARD_VERSION : ${{ matrix.vshard-version }}
60100
61101 - name : Install metrics
62102 if : matrix.metrics-version != ''
63- run : tarantoolctl rocks install metrics ${{ matrix.metrics-version }}
103+ run : tt rocks install metrics ${{ matrix.metrics-version }}
64104
65105 - name : Remove external merger if needed
66106 if : ${{ matrix.remove-merger }}
@@ -90,23 +130,64 @@ jobs:
90130 matrix :
91131 tarantool-version : ["1.10", "2.11"]
92132 metrics-version : ["1.0.0"]
133+ cartridge-version : ["2.8.0"]
134+ include :
135+ - tarantool-version : " master"
136+ metrics-version : " 1.0.0"
137+ vshard-version : " 0.1.24"
93138 fail-fast : false
94139 runs-on : ubuntu-20.04
95140 steps :
96141 - uses : actions/checkout@master
97142
98143 - name : Setup Tarantool CE
144+ if : matrix.tarantool-version != 'master'
99145 uses : tarantool/setup-tarantool@v2
100146 with :
101147 tarantool-version : ${{ matrix.tarantool-version }}
102148
149+ - name : Setup tt
150+ run : |
151+ curl -L https://tarantool.io/release/2/installer.sh | sudo bash
152+ sudo apt install -y tt
153+ tt version
154+
155+ - name : Get Tarantool master latest commit
156+ if : matrix.tarantool-version == 'master'
157+ run : |
158+ commit_hash=$(git ls-remote https://github.com/tarantool/tarantool.git --branch master | head -c 8)
159+ echo "LATEST_COMMIT=${commit_hash}" >> $GITHUB_ENV
160+ shell : bash
161+
162+ - name : Cache Tarantool master
163+ if : matrix.tarantool-version == 'master'
164+ id : cache-latest
165+ uses : actions/cache@v3
166+ with :
167+ path : " ${GITHUB_WORKSPACE}/bin"
168+ key : cache-latest-${{ env.LATEST_COMMIT }}
169+
170+ - name : Setup Tarantool master
171+ if : matrix.tarantool-version == 'master' && steps.cache-latest.outputs.cache-hit != 'true'
172+ run : |
173+ tt init
174+ tt install tarantool master
175+
176+ - name : Add Tarantool master to PATH
177+ if : matrix.tarantool-version == 'master'
178+ run : echo "${GITHUB_WORKSPACE}/bin" >> $GITHUB_PATH
179+
103180 - name : Install requirements for community
104181 run : |
105182 tarantool --version
106183 ./deps.sh
184+ env :
185+ CARTRIDGE_VERSION : ${{ matrix.cartridge-version }}
186+ VSHARD_VERSION : ${{ matrix.vshard-version }}
107187
108188 - name : Install metrics
109- run : tarantoolctl rocks install metrics ${{ matrix.metrics-version }}
189+ if : matrix.metrics-version != ''
190+ run : tt rocks install metrics ${{ matrix.metrics-version }}
110191
111192 # This server starts and listen on 8084 port that is used for tests
112193 - name : Stop Mono server
@@ -127,6 +208,7 @@ jobs:
127208 - folder : " 2.11"
128209 bundle : " tarantool-enterprise-sdk-nogc64-2.11.0-0-r563.linux.x86_64"
129210 metrics-version : ["", "1.0.0"]
211+ cartridge-version : ["2.8.0"]
130212 fail-fast : false
131213 runs-on : ubuntu-20.04
132214 steps :
@@ -138,9 +220,13 @@ jobs:
138220 tar -xzf ${{ matrix.tarantool-version.bundle }}.tar.gz
139221 rm -f ${{ matrix.tarantool-version.bundle }}.tar.gz
140222 sudo cp tarantool-enterprise/tarantool /usr/bin/tarantool
223+ sudo rm tarantool-enterprise/tt
141224 source tarantool-enterprise/env.sh
142225 tarantool --version
143226 ./deps.sh
227+ env :
228+ CARTRIDGE_VERSION : ${{ matrix.cartridge-version }}
229+ VSHARD_VERSION : ${{ matrix.vshard-version }}
144230
145231 - name : Install metrics
146232 if : matrix.metrics-version != ''
0 commit comments