-
Notifications
You must be signed in to change notification settings - Fork 17
Open
Description
HI, I'm trying to connect directly to the redis server from the integration test by adding a container_name to the redis service in the compose yaml like this:
version: '2'
services:
counter:
image: gcr.io/${PROJECT_ID}/gcb-docker-compose:latest
container_name: counter
depends_on:
- redis
ports:
- "50051:50051"
environment:
- REDIS_HOST=redis
- REDIS_PORT=6379
redis:
container_name: redis
image: redis
ports:
- "6379:6379"
networks:
default:
external:
name: cloudbuild
And then doing in the integration test step:
const redisClient = redis.createClient({host: 'redis', port: '6379');
But I get an error in the cloud build console:
Step #2: (node:26) UnhandledPromiseRejectionWarning: Error: connect ECONNREFUSED 192.168.10.4:6379
Step #2: at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1191:14)
Any idea why?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels