Skip to content

Commit 5502c95

Browse files
authored
RI-5362 Fix nightly tests running (#4245)
* mount /data directory to containers * use proper connection uri * change RI port * create COV_DIRECTORY explicitly * remove double mkdir * use shared volume
1 parent 0eecbbe commit 5502c95

File tree

5 files changed

+23
-10
lines changed

5 files changed

+23
-10
lines changed

.circleci/build/build.Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ RUN mkdir -p /data && chown -R node:node /data
2828
COPY --chown=node:node ./docker-entry.sh ./
2929
RUN chmod +x docker-entry.sh
3030

31-
# since RI is hard-code to port 5000, expose it from the container
32-
EXPOSE 5000
31+
# since RI is hard-code to port 5540, expose it from the container
32+
EXPOSE 5540
3333

3434
# don't run the node process as root
3535
USER node

.github/build/build.Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ RUN mkdir -p /data && chown -R node:node /data
2828
COPY --chown=node:node ./docker-entry.sh ./
2929
RUN chmod +x docker-entry.sh
3030

31-
# since RI is hard-code to port 5000, expose it from the container
32-
EXPOSE 5000
31+
# since RI is hard-code to port 5540, expose it from the container
32+
EXPOSE 5540
3333

3434
# don't run the node process as root
3535
USER node

.github/workflows/tests-integration.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,10 @@ jobs:
114114
run: |
115115
docker image load -i ./release/docker/docker-linux-alpine.amd64.tar
116116
117+
- name: Make sure coverage dir exists
118+
# Important: this directory is mounted on both the `app` and `test` Docker containers.
119+
run: mkdir -p ./redisinsight/api/test/test-runs/coverage
120+
117121
- name: Run tests
118122
timeout-minutes: 20
119123
run: |
@@ -122,7 +126,7 @@ jobs:
122126
fi
123127
124128
./redisinsight/api/test/test-runs/start-test-run.sh -r ${{ matrix.rte }} -t ${{ inputs.build }}
125-
mkdir -p mkdir itest/coverages && mkdir -p itest/results
129+
mkdir -p itest/coverages && mkdir -p itest/results
126130
127131
cp ./redisinsight/api/test/test-runs/coverage/test-run-result.json ./itest/results/${{ matrix.rte }}.result.json
128132
cp ./redisinsight/api/test/test-runs/coverage/test-run-result.xml ./itest/results/${{ matrix.rte }}.result.xml
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
COV_FOLDER=./coverage
22
ID=defaultid
33
RTE=defaultrte
4-
APP_IMAGE=riv2:latest
5-
TEST_BE_SERVER=https://app:5000/api
4+
APP_IMAGE=redisinsight:amd64
5+
TEST_BE_SERVER=http://app:5540/api
66
RI_NOTIFICATION_UPDATE_URL=https://s3.amazonaws.com/redisinsight.test/public/tests/notifications.json
77
CERTS_FOLDER=/root/.redisinsight-v2.0

redisinsight/api/test/test-runs/docker.build.yml

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,9 @@ services:
1414
dockerfile: ./test/test-runs/test.Dockerfile
1515
tty: true
1616
volumes:
17-
- ${COV_FOLDER}:/usr/src/app/coverage
18-
- ${COV_FOLDER}:/root/.redisinsight-v2.0
17+
- shared-data:/usr/src/app/coverage
18+
- shared-data:/root/.redisinsight-v2.0
19+
- shared-data:/data
1920
depends_on:
2021
- redis
2122
- app
@@ -34,7 +35,8 @@ services:
3435
depends_on:
3536
- redis
3637
volumes:
37-
- ${COV_FOLDER}:/root/.redisinsight-v2.0
38+
- shared-data:/root/.redisinsight-v2.0
39+
- shared-data:/data
3840
environment:
3941
RI_REDIS_CLIENTS_FORCE_STRATEGY: ${RI_REDIS_CLIENTS_FORCE_STRATEGY}
4042
CERTS_FOLDER: "/root/.redisinsight-v2.0"
@@ -49,3 +51,10 @@ networks:
4951
default:
5052
name: ${ID}
5153

54+
volumes:
55+
shared-data:
56+
driver: local
57+
driver_opts:
58+
type: none
59+
device: ${COV_FOLDER}
60+
o: bind

0 commit comments

Comments
 (0)