Skip to content

Commit 06e2cdb

Browse files
committed
feat: experimental
1 parent 6debdbb commit 06e2cdb

File tree

3 files changed

+36
-15
lines changed

3 files changed

+36
-15
lines changed

.github/workflows/keploy.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ jobs:
4343
4444
- name: Run the node-express-graphql template
4545
run: |
46+
docker compose -f docker-compose-1.yml --env-file=.env.docker up -d
4647
chmod +x /home/runner/work/node-express-graphql-template/node-express-graphql-template/.github/workflows/test_workflows/keploy.sh
4748
/home/runner/work/node-express-graphql-template/node-express-graphql-template/.github/workflows/test_workflows/keploy.sh
4849
env:

docker-compose-1.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
version: '3'
2+
networks:
3+
node-express-graphql-template_default: {}
4+
services:
5+
db_postgres:
6+
networks:
7+
- node-express-graphql-template_default
8+
image: postgres
9+
ports:
10+
- 5432:5432
11+
restart: always
12+
env_file:
13+
- ./.env.docker
14+
redis:
15+
networks:
16+
- node-express-graphql-template_default
17+
image: 'redis:alpine'
18+
depends_on:
19+
wait-for-db:
20+
condition: service_completed_successfully
21+
ports:
22+
- '6379:6379'
23+
command: ['redis-server', '--bind', 'redis', '--port', '6379']
24+
wait-for-db:
25+
networks:
26+
- node-express-graphql-template_default
27+
image: atkrad/wait4x
28+
depends_on:
29+
- db_postgres
30+
command: tcp db_postgres:${POSTGRES_PORT} -t 30s -i 250ms

docker-compose.yml

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,11 @@
11
version: '3'
2+
networks:
3+
node-express-graphql-template_node-express-graphql-template_default:
4+
external: true
25
services:
3-
db_postgres:
4-
image: postgres
5-
ports:
6-
- 5432:5432
7-
restart: always
8-
env_file:
9-
- .env.docker
10-
redis:
11-
image: 'redis:alpine'
12-
ports:
13-
- '6379:6379'
14-
command: ['redis-server', '--bind', 'redis', '--port', '6379']
156
app:
7+
networks:
8+
- node-express-graphql-template_node-express-graphql-template_default
169
build:
1710
context: .
1811
args:
@@ -21,9 +14,6 @@ services:
2114
PLATFORM: amd64
2215
APP_PATH: ${APP_PATH}
2316
restart: always
24-
depends_on:
25-
- db_postgres
26-
- redis
2717
ports:
2818
- 9000:9000
2919
environment:

0 commit comments

Comments
 (0)