# (111: Connection refused) while connecting to upstream

**URL:** <https://discuss.konghq.com/t/111-connection-refused-while-connecting-to-upstream/6068>\
**Category:** General\
**Tags:** service-mesh\
**Created:** [April 18, 2020, 11:08am UTC](https://discuss.konghq.com/t/111-connection-refused-while-connecting-to-upstream/6068 "2020-04-18T11:08:07Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jaiswar.vipin](https://yyz2.discourse-cdn.com/flex036/user_avatar/discuss.konghq.com/jaiswar.vipin/32/1873_2.png) [@jaiswar.vipin](https://discuss.konghq.com/u/jaiswar.vipin)\
**Post date:** [April 18, 2020, 11:08am UTC](https://discuss.konghq.com/t/111-connection-refused-while-connecting-to-upstream/6068/1 "2020-04-18T11:08:07Z")

</div>

Hi All,  
Currently i have deployed the “Kong Community” version on my local m/c and running under the docker along with same i had expose a Node.Js web-service on 8090 port. same time i am using KONGA as portal to mane the API.

So here is details…

**Step1: KONG - docker-compose.yaml**

> version: ‘2.1’
> 
> volumes:  
> kong\_data: {}
> 
> networks:  
> kong-net:
> 
> services:  
> kong-migrations:  
> image: “${KONG\_DOCKER\_TAG:-kong:latest}”  
> command: kong migrations bootstrap  
> depends\_on:  
> db:  
> condition: service\_healthy  
> environment:  
> KONG\_DATABASE: postgres  
> KONG\_PG\_DATABASE: ${KONG\_PG\_DATABASE:-kong}  
> KONG\_PG\_HOST: db  
> KONG\_PG\_PASSWORD: ${KONG\_PG\_PASSWORD:-kong}  
> KONG\_PG\_USER: ${KONG\_PG\_USER:-kong}  
> networks:  
> - kong-net  
> restart: on-failure
> 
> kong-migrations-up:  
> image: “${KONG\_DOCKER\_TAG:-kong:latest}”  
> command: kong migrations up && kong migrations finish  
> depends\_on:  
> db:  
> condition: service\_healthy  
> environment:  
> KONG\_DATABASE: postgres  
> KONG\_PG\_DATABASE: ${KONG\_PG\_DATABASE:-kong}  
> KONG\_PG\_HOST: db  
> KONG\_PG\_PASSWORD: ${KONG\_PG\_PASSWORD:-kong}  
> KONG\_PG\_USER: ${KONG\_PG\_USER:-kong}  
> networks:  
> - kong-net  
> restart: on-failure
> 
> kong:  
> image: “${KONG\_DOCKER\_TAG:-kong:latest}”  
> user: “${KONG\_USER:-kong}”  
> depends\_on:  
> db:  
> condition: service\_healthy  
> environment:  
> KONG\_ADMIN\_ACCESS\_LOG: /dev/stdout  
> KONG\_ADMIN\_ERROR\_LOG: /dev/stderr  
> KONG\_ADMIN\_LISTEN: ‘0.0.0.0:8001’  
> KONG\_CASSANDRA\_CONTACT\_POINTS: db  
> KONG\_DATABASE: postgres  
> KONG\_PG\_DATABASE: ${KONG\_PG\_DATABASE:-kong}  
> KONG\_PG\_HOST: db  
> KONG\_PG\_PASSWORD: ${KONG\_PG\_PASSWORD:-kong}  
> KONG\_PG\_USER: ${KONG\_PG\_USER:-kong}  
> KONG\_PROXY\_ACCESS\_LOG: /dev/stdout  
> KONG\_PROXY\_ERROR\_LOG: /dev/stderr  
> networks:  
> - kong-net  
> ports:  
> - “8000:8000/tcp”  
> - “8001:8001/tcp”  
> - “8443:8443/tcp”  
> - “8444:8444/tcp”  
> healthcheck:  
> test: [“CMD”, “kong”, “health”]  
> interval: 10s  
> timeout: 10s  
> retries: 10  
> restart: on-failure
> 
> db:  
> image: postgres:9.5  
> environment:  
> POSTGRES\_DB: ${KONG\_PG\_DATABASE:-kong}  
> POSTGRES\_PASSWORD: ${KONG\_PG\_PASSWORD:-kong}  
> POSTGRES\_USER: ${KONG\_PG\_USER:-kong}  
> healthcheck:  
> test: [“CMD”, “pg\_isready”, “-U”, “${KONG\_PG\_USER:-kong}”]  
> interval: 30s  
> timeout: 30s  
> retries: 3  
> restart: on-failure  
> stdin\_open: true  
> tty: true  
> networks:  
> - kong-net  
> volumes:  
> - kong\_data:/var/lib/postgresql/data

**Step 2: running the kong**

> docker-compose -f docker-compose.yaml up

**Step3: Hosting API using KONGA**

 ![konga](https://canada1.discourse-cdn.com/flex036/uploads/konghq/original/2X/a/a34e04dcbc06d8d55c5f143959803f042a81cfc5.png)

**Step 4: Executing the API using POSTman getting following error**

 ![konga](https://canada1.discourse-cdn.com/flex036/uploads/konghq/original/2X/e/ed9d53773e864a40a840b9de2183141fe52f5fe8.png)

**Step5: POSTMAN output**

 ![konga](https://canada1.discourse-cdn.com/flex036/uploads/konghq/original/2X/8/8f02acc497b8431286591bfa09b0a4a590ab6e21.png)

**Step6: Node.js Service Output**

> End Point: [http://127.0.0.1:8090/tokenVerification/](http://127.0.0.1:8090/tokenVerification/)

Response:

> {  
> “responseType”: “INVALID”,  
> “status”: “UN-SUCCESS”,  
> “message”: “Un-Successfully Validated”  
> }

**Execution Environment**

- Windows Firewall is off
- All Port (inbound and outbound) is open
- Docker running on windows 10

Kindly Assist.

**Thanks & Regards**  
Jaiswar Vipin Kumar R.

---

<div class="post-metadata">

**Author:** ![suresh\_m](https://avatars.discourse-cdn.com/v4/letter/s/e68b1a/32.png) [@suresh\_m](https://discuss.konghq.com/u/suresh_m)\
**Post date:** [December 19, 2021, 12:29pm UTC](https://discuss.konghq.com/t/111-connection-refused-while-connecting-to-upstream/6068/2 "2021-12-19T12:29:55Z")

</div>

1. verify the End Point: [http://127.0.0.1:8090/tokenVerification/](http://127.0.0.1:8090/tokenVerification/) is running and necessary firewalls are open any connection reset timeout set at endpoint side
2. reboot the kong ingress pod then try to test again
