Skip to content

Commit 69186e9

Browse files
committed
🩺(CI) wait for services to be ready
We add a check to be sure all the services are ready before starting the e2e tests.
1 parent f606826 commit 69186e9

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

.github/workflows/impress-frontend.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,28 @@ jobs:
9696
- name: Install Playwright Browsers
9797
run: cd src/frontend/apps/e2e && yarn install-playwright chromium
9898

99+
# Tool to wait for a service to be ready
100+
- name: Install Dockerize
101+
run: |
102+
curl -sSL https://github.com/jwilder/dockerize/releases/download/v0.8.0/dockerize-linux-amd64-v0.8.0.tar.gz | sudo tar -C /usr/local/bin -xzv
103+
104+
- name: Wait for services to be ready
105+
run: |
106+
printf "Minio check...\n"
107+
dockerize -wait tcp://localhost:9000 -timeout 20s
108+
printf "Keyclock check...\n"
109+
dockerize -wait tcp://localhost:8080 -timeout 20s
110+
printf "Server collaboration check...\n"
111+
dockerize -wait tcp://localhost:4444 -timeout 20s
112+
printf "Ngnix check...\n"
113+
dockerize -wait tcp://localhost:8083 -timeout 20s
114+
printf "DRF check...\n"
115+
dockerize -wait tcp://localhost:8071 -timeout 20s
116+
printf "Postgres Keyclock check...\n"
117+
dockerize -wait tcp://localhost:5433 -timeout 20s
118+
printf "Postgres back check...\n"
119+
dockerize -wait tcp://localhost:15432 -timeout 20s
120+
99121
- name: Run e2e tests
100122
run: cd src/frontend/ && yarn e2e:test --project='chromium'
101123

0 commit comments

Comments
 (0)